home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1996-06-17 | 48.4 KB | [TEXT/CWIE] |
open in:
MacOS 8.1
|
Win98
|
DOS
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary).
You can browse this item here: VideoToolbox.h
Confidence | Program | Detection | Match Type | Support
|
---|
10%
| dexvert
| MacBinary (archive/macBinary)
| fallback
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| MacBinary II, inited, Mon Jun 17 20:48:55 1996, modified Mon Jun 17 20:48:55 1996, creator 'CWIE', type ASCII, 48781 bytes "VideoToolbox.h" , at 0xbf0d 456 bytes resource
| default (weak)
| |
99%
| file
| data
| default
| |
74%
| TrID
| Macintosh plain text (MacBinary)
| default
| |
25%
| TrID
| MacBinary 2
| default (weak)
| |
100%
| siegfried
| fmt/1762 MacBinary (II)
| default
| |
100%
| lsar
| MacBinary
| default
|
|
id metadata |
---|
key | value |
---|
macFileType | [TEXT] |
macFileCreator | [CWIE] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0e 56 69 64 65 6f 54 | 6f 6f 6c 62 6f 78 2e 68 |..VideoT|oolbox.h|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 43 57 49 | 45 01 00 00 00 00 00 00 |.TEXTCWI|E.......|
|00000050| 00 00 00 00 00 be 8d 00 | 00 01 c8 ad eb ad 77 ad |........|......w.|
|00000060| eb ad 77 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |..w.....|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 59 be 00 00 |........|....Y...|
|00000080| 2f 2a 0d 56 69 64 65 6f | 54 6f 6f 6c 62 6f 78 2e |/*.Video|Toolbox.|
|00000090| 68 0d 54 68 69 73 20 66 | 69 6c 65 20 63 6f 6e 74 |h.This f|ile cont|
|000000a0| 61 69 6e 73 20 74 68 65 | 20 6e 65 63 65 73 73 61 |ains the| necessa|
|000000b0| 72 79 20 70 72 6f 74 6f | 74 79 70 65 73 20 66 6f |ry proto|types fo|
|000000c0| 72 20 75 73 65 20 6f 66 | 20 61 6c 6c 20 74 68 65 |r use of| all the|
|000000d0| 20 56 69 64 65 6f 54 6f | 6f 6c 62 6f 78 0d 66 69 | VideoTo|olbox.fi|
|000000e0| 6c 65 73 20 65 78 63 65 | 70 74 20 4c 75 6d 69 6e |les exce|pt Lumin|
|000000f0| 61 6e 63 65 2e 63 2c 20 | 77 68 69 63 68 20 68 61 |ance.c, |which ha|
|00000100| 73 20 69 74 73 20 6f 77 | 6e 20 68 65 61 64 65 72 |s its ow|n header|
|00000110| 20 66 69 6c 65 2c 20 4c | 75 6d 69 6e 61 6e 63 65 | file, L|uminance|
|00000120| 2e 68 2c 20 61 6e 64 0d | 47 44 49 6e 66 6f 2e 63 |.h, and.|GDInfo.c|
|00000130| 20 61 6e 64 20 47 44 54 | 65 73 74 43 6c 75 74 2e | and GDT|estClut.|
|00000140| 63 2c 20 77 68 69 63 68 | 20 75 73 65 20 47 44 49 |c, which| use GDI|
|00000150| 6e 66 6f 2e 68 2e 0d 0d | 50 72 65 63 6f 6d 70 69 |nfo.h...|Precompi|
|00000160| 6c 61 74 69 6f 6e 20 6f | 66 20 74 68 69 73 20 68 |lation o|f this h|
|00000170| 65 61 64 65 72 2c 20 70 | 72 6f 64 75 63 69 6e 67 |eader, p|roducing|
|00000180| 20 65 69 74 68 65 72 20 | 56 69 64 65 6f 54 6f 6f | either |VideoToo|
|00000190| 6c 62 6f 78 3f 3f 3f 3f | 2e 70 72 65 20 6f 72 0d |lbox????|.pre or.|
|000001a0| 56 69 64 65 6f 54 6f 6f | 6c 62 6f 78 4d 41 54 4c |VideoToo|lboxMATL|
|000001b0| 41 42 3f 3f 3f 3f 2e 70 | 72 65 2c 20 77 69 6c 6c |AB????.p|re, will|
|000001c0| 20 72 65 64 75 63 65 20 | 79 6f 75 72 20 63 6f 6d | reduce |your com|
|000001d0| 70 69 6c 61 74 69 6f 6e | 20 74 69 6d 65 20 74 65 |pilation| time te|
|000001e0| 6e 66 6f 6c 64 2e 20 53 | 65 65 0d 56 69 64 65 6f |nfold. S|ee.Video|
|000001f0| 54 6f 6f 6c 62 6f 78 2e | 70 63 68 2c 20 6f 72 20 |Toolbox.|pch, or |
|00000200| 56 69 64 65 6f 54 6f 6f | 6c 62 6f 78 2e 63 2c 20 |VideoToo|lbox.c, |
|00000210| 6f 72 20 56 69 64 65 6f | 54 6f 6f 6c 62 6f 78 4d |or Video|ToolboxM|
|00000220| 41 54 4c 41 42 2e 63 20 | 66 6f 72 20 69 6e 73 74 |ATLAB.c |for inst|
|00000230| 72 75 63 74 69 6f 6e 73 | 2e 0d 0d 4d 79 20 63 6f |ructions|...My co|
|00000240| 6e 76 65 6e 74 69 6f 6e | 20 69 73 20 74 6f 20 61 |nvention| is to a|
|00000250| 73 73 69 67 6e 20 64 69 | 66 66 65 72 65 6e 74 20 |ssign di|fferent |
|00000260| 6e 61 6d 65 73 20 74 6f | 20 74 68 65 20 70 72 65 |names to| the pre|
|00000270| 63 6f 6d 70 69 6c 65 64 | 20 68 65 61 64 65 72 20 |compiled| header |
|00000280| 64 65 70 65 6e 64 69 6e | 67 0d 6f 6e 20 74 68 65 |dependin|g.on the|
|00000290| 20 63 6f 6d 70 69 6c 65 | 2d 74 69 6d 65 20 6f 70 | compile|-time op|
|000002a0| 74 69 6f 6e 73 3a 20 75 | 73 65 20 6f 66 20 70 70 |tions: u|se of pp|
|000002b0| 63 2f 36 38 6b 2c 20 36 | 38 38 38 31 2c 20 61 6e |c/68k, 6|8881, an|
|000002c0| 64 20 73 69 7a 65 20 6f | 66 20 69 6e 74 2e 0d 0d |d size o|f int...|
|000002d0| 54 68 65 20 70 72 65 63 | 6f 6d 70 69 6c 61 74 69 |The prec|ompilati|
|000002e0| 6f 6e 20 64 65 70 65 6e | 64 73 20 6f 6e 20 74 68 |on depen|ds on th|
|000002f0| 65 20 73 69 7a 65 6f 66 | 28 64 6f 75 62 6c 65 29 |e sizeof|(double)|
|00000300| 20 61 6e 64 20 73 69 7a | 65 6f 66 28 69 6e 74 29 | and siz|eof(int)|
|00000310| 0d 62 65 63 61 75 73 65 | 20 6d 6f 73 74 20 66 75 |.because| most fu|
|00000320| 6e 63 74 69 6f 6e 73 20 | 75 73 65 20 6f 72 20 72 |nctions |use or r|
|00000330| 65 74 75 72 6e 20 73 75 | 63 68 20 76 61 6c 75 65 |eturn su|ch value|
|00000340| 73 20 61 6e 64 20 74 68 | 65 20 65 78 74 65 72 6e |s and th|e extern|
|00000350| 61 6c 20 69 6e 74 65 72 | 66 61 63 65 20 6d 75 73 |al inter|face mus|
|00000360| 74 0d 61 6c 6c 6f 77 20 | 74 68 65 20 61 70 70 72 |t.allow |the appr|
|00000370| 6f 70 72 69 61 74 65 20 | 61 6d 6f 75 6e 74 20 6f |opriate |amount o|
|00000380| 66 20 73 70 61 63 65 2e | 20 54 48 49 4e 4b 20 43 |f space.| THINK C|
|00000390| 20 73 75 70 70 6f 72 74 | 73 20 61 20 31 32 2d 62 | support|s a 12-b|
|000003a0| 79 74 65 20 22 75 6e 69 | 76 65 72 73 61 6c 22 0d |yte "uni|versal".|
|000003b0| 66 6f 72 6d 61 74 20 64 | 6f 75 62 6c 65 20 74 68 |format d|ouble th|
|000003c0| 61 74 20 77 6f 72 6b 73 | 20 77 65 6c 6c 20 62 6f |at works| well bo|
|000003d0| 74 68 20 77 69 74 68 20 | 74 68 65 20 36 38 38 38 |th with |the 6888|
|000003e0| 31 20 66 70 75 20 28 77 | 68 69 63 68 20 75 73 65 |1 fpu (w|hich use|
|000003f0| 73 20 74 68 65 20 74 6f | 70 20 74 77 6f 0d 62 79 |s the to|p two.by|
|00000400| 74 65 73 20 61 6e 64 20 | 74 68 65 20 62 6f 74 74 |tes and |the bott|
|00000410| 6f 6d 20 38 20 62 79 74 | 65 73 29 20 61 6e 64 20 |om 8 byt|es) and |
|00000420| 77 69 74 68 20 53 41 4e | 45 20 28 77 68 69 63 68 |with SAN|E (which|
|00000430| 20 75 73 65 73 20 74 68 | 65 20 62 6f 74 74 6f 6d | uses th|e bottom|
|00000440| 20 31 30 20 62 79 74 65 | 73 29 2e 0d 54 68 75 73 | 10 byte|s)..Thus|
|00000450| 20 69 6e 20 54 48 49 4e | 4b 20 43 20 69 74 20 69 | in THIN|K C it i|
|00000460| 73 20 65 61 73 79 20 74 | 6f 20 6d 69 78 20 6d 6f |s easy t|o mix mo|
|00000470| 64 75 6c 65 73 20 63 6f | 6d 70 69 6c 65 64 20 77 |dules co|mpiled w|
|00000480| 69 74 68 20 28 65 2e 67 | 2e 20 79 6f 75 72 20 63 |ith (e.g|. your c|
|00000490| 6f 64 65 29 20 61 6e 64 | 0d 77 69 74 68 6f 75 74 |ode) and|.without|
|000004a0| 20 28 65 2e 67 2e 20 74 | 68 65 20 41 4e 53 49 20 | (e.g. t|he ANSI |
|000004b0| 6c 69 62 72 61 72 79 29 | 20 74 68 65 20 36 38 38 |library)| the 688|
|000004c0| 38 31 20 6f 70 74 69 6f | 6e 2e 20 55 6e 66 6f 72 |81 optio|n. Unfor|
|000004d0| 74 75 6e 61 74 65 6c 79 | 20 74 68 61 74 20 65 78 |tunately| that ex|
|000004e0| 63 65 6c 6c 65 6e 74 0d | 66 65 61 74 75 72 65 20 |cellent.|feature |
|000004f0| 69 73 20 75 6e 69 71 75 | 65 20 74 6f 20 54 48 49 |is uniqu|e to THI|
|00000500| 4e 4b 20 43 2e 20 49 6e | 20 4d 50 57 20 61 6e 64 |NK C. In| MPW and|
|00000510| 20 43 6f 64 65 57 61 72 | 72 69 6f 72 20 43 20 79 | CodeWar|rior C y|
|00000520| 6f 75 20 6d 75 73 74 20 | 75 73 65 20 31 30 2d 62 |ou must |use 10-b|
|00000530| 79 74 65 0d 64 6f 75 62 | 6c 65 73 20 77 68 65 6e |yte.doub|les when|
|00000540| 20 79 6f 75 20 75 73 65 | 20 53 41 4e 45 20 28 69 | you use| SANE (i|
|00000550| 2e 65 2e 20 64 6f 6e 27 | 74 20 75 73 65 20 74 68 |.e. don'|t use th|
|00000560| 65 20 36 38 38 38 31 20 | 66 70 75 29 2c 20 73 6f |e 68881 |fpu), so|
|00000570| 20 77 68 65 6e 20 79 6f | 75 20 75 73 65 20 74 68 | when yo|u use th|
|00000580| 65 73 65 0d 63 6f 6d 70 | 69 6c 65 72 73 20 79 6f |ese.comp|ilers yo|
|00000590| 75 27 6c 6c 20 6e 65 65 | 64 20 73 65 70 61 72 61 |u'll nee|d separa|
|000005a0| 74 65 20 70 72 65 2d 63 | 6f 6d 70 69 6c 65 64 20 |te pre-c|ompiled |
|000005b0| 68 65 61 64 65 72 73 2c | 20 77 69 74 68 20 61 6e |headers,| with an|
|000005c0| 64 20 77 69 74 68 6f 75 | 74 20 74 68 65 20 36 38 |d withou|t the 68|
|000005d0| 38 38 31 0d 6f 70 74 69 | 6f 6e 2c 20 69 66 20 79 |881.opti|on, if y|
|000005e0| 6f 75 20 77 61 6e 74 20 | 74 6f 20 63 6f 6d 70 69 |ou want |to compi|
|000005f0| 6c 65 20 66 6f 72 20 65 | 61 63 68 20 65 6e 76 69 |le for e|ach envi|
|00000600| 72 6f 6e 6d 65 6e 74 3a | 20 74 6f 20 75 73 65 20 |ronment:| to use |
|00000610| 74 68 65 20 36 38 38 38 | 31 20 66 70 75 2c 20 6f |the 6888|1 fpu, o|
|00000620| 72 0d 72 75 6e 20 6f 6e | 20 6d 61 63 68 69 6e 65 |r.run on| machine|
|00000630| 73 20 74 68 61 74 20 6c | 61 63 6b 20 69 74 2e 0d |s that l|ack it..|
|00000640| 0d 4d 65 74 72 6f 77 65 | 72 6b 73 20 43 6f 64 65 |.Metrowe|rks Code|
|00000650| 57 61 72 72 69 6f 72 20 | 70 72 6f 6a 65 63 74 20 |Warrior |project |
|00000660| 6e 61 6d 65 73 20 65 6e | 64 20 69 6e 20 22 b5 22 |names en|d in "."|
|00000670| 2c 20 61 6e 64 20 69 6e | 64 69 63 61 74 65 20 77 |, and in|dicate w|
|00000680| 68 69 63 68 20 63 70 75 | 20 74 68 65 79 0d 73 75 |hich cpu| they.su|
|00000690| 70 70 6f 72 74 20 62 79 | 20 22 36 38 6b 22 20 6f |pport by| "68k" o|
|000006a0| 72 20 22 70 70 63 22 2e | 20 54 48 49 4e 4b 20 43 |r "ppc".| THINK C|
|000006b0| 20 70 72 6f 6a 65 63 74 | 73 20 73 75 70 70 6f 72 | project|s suppor|
|000006c0| 74 20 6f 6e 6c 79 20 74 | 68 65 20 36 38 6b 20 61 |t only t|he 68k a|
|000006d0| 6e 64 20 68 61 76 65 20 | 6e 61 6d 65 73 0d 65 6e |nd have |names.en|
|000006e0| 64 69 6e 67 20 69 6e 20 | 22 b9 22 2e 0d 0d 4d 79 |ding in |"."...My|
|000006f0| 20 6e 61 6d 69 6e 67 20 | 63 6f 6e 76 65 6e 74 69 | naming |conventi|
|00000700| 6f 6e 20 66 6f 72 20 70 | 72 65 2d 63 6f 6d 70 69 |on for p|re-compi|
|00000710| 6c 65 64 20 68 65 61 64 | 65 72 73 20 69 6e 64 69 |led head|ers indi|
|00000720| 63 61 74 65 73 20 74 68 | 65 20 73 69 7a 65 20 6f |cates th|e size o|
|00000730| 66 20 69 6e 74 2c 20 22 | 32 69 22 20 6f 72 0d 22 |f int, "|2i" or."|
|00000740| 34 69 22 2c 20 61 6e 64 | 2c 20 69 66 20 74 68 65 |4i", and|, if the|
|00000750| 20 36 38 38 38 31 20 69 | 73 20 72 65 71 75 69 72 | 68881 i|s requir|
|00000760| 65 64 2c 20 22 38 38 31 | 22 2e 20 4d 65 74 72 6f |ed, "881|". Metro|
|00000770| 77 65 72 6b 73 20 70 72 | 65 2d 63 6f 6d 70 69 6c |werks pr|e-compil|
|00000780| 65 64 20 68 65 61 64 65 | 72 73 0d 69 6e 64 69 63 |ed heade|rs.indic|
|00000790| 61 74 65 20 77 68 69 63 | 68 20 63 70 75 20 74 68 |ate whic|h cpu th|
|000007a0| 65 79 20 73 75 70 70 6f | 72 74 20 62 79 20 22 36 |ey suppo|rt by "6|
|000007b0| 38 6b 22 20 6f 72 20 22 | 70 70 63 22 3b 20 54 48 |8k" or "|ppc"; TH|
|000007c0| 49 4e 4b 20 43 20 73 75 | 70 70 6f 72 74 73 20 6f |INK C su|pports o|
|000007d0| 6e 6c 79 20 74 68 65 0d | 36 38 6b 2e 20 54 68 65 |nly the.|68k. The|
|000007e0| 20 54 48 49 4e 4b 20 43 | 20 70 72 65 2d 63 6f 6d | THINK C| pre-com|
|000007f0| 70 69 6c 65 64 20 68 65 | 61 64 65 72 20 74 68 61 |piled he|ader tha|
|00000800| 74 20 49 20 75 73 65 20 | 69 73 20 22 56 69 64 65 |t I use |is "Vide|
|00000810| 6f 54 6f 6f 6c 62 6f 78 | 2e 70 72 65 22 2c 20 77 |oToolbox|.pre", w|
|00000820| 68 69 63 68 0d 75 73 65 | 73 20 32 2d 62 79 74 65 |hich.use|s 2-byte|
|00000830| 20 69 6e 74 73 20 61 6e | 64 20 22 75 6e 69 76 65 | ints an|d "unive|
|00000840| 72 73 61 6c 22 20 31 32 | 2d 62 79 74 65 20 64 6f |rsal" 12|-byte do|
|00000850| 75 62 6c 65 73 20 74 68 | 61 74 20 77 6f 72 6b 20 |ubles th|at work |
|00000860| 77 69 74 68 20 6f 72 20 | 77 69 74 68 6f 75 74 20 |with or |without |
|00000870| 74 68 65 0d 36 38 38 38 | 31 2e 20 28 54 68 65 20 |the.6888|1. (The |
|00000880| 54 48 49 4e 4b 20 43 20 | 41 4e 53 49 20 6c 69 62 |THINK C |ANSI lib|
|00000890| 72 61 72 79 20 72 65 71 | 75 69 72 65 73 20 32 2d |rary req|uires 2-|
|000008a0| 62 79 74 65 20 69 6e 74 | 73 2e 29 20 54 68 65 20 |byte int|s.) The |
|000008b0| 4d 65 74 72 6f 77 65 72 | 6b 73 0d 43 6f 64 65 57 |Metrower|ks.CodeW|
|000008c0| 61 72 72 69 6f 72 20 43 | 20 70 72 65 2d 63 6f 6d |arrior C| pre-com|
|000008d0| 70 69 6c 65 64 20 68 65 | 61 64 65 72 73 20 74 68 |piled he|aders th|
|000008e0| 61 74 20 49 20 75 73 65 | 20 61 72 65 20 63 61 6c |at I use| are cal|
|000008f0| 6c 65 64 2c 0d 22 56 69 | 64 65 6f 54 6f 6f 6c 62 |led,."Vi|deoToolb|
|00000900| 6f 78 2e 36 38 6b 2e 34 | 69 2e 70 72 65 22 2c 20 |ox.68k.4|i.pre", |
|00000910| 22 56 69 64 65 6f 54 6f | 6f 6c 62 6f 78 2e 36 38 |"VideoTo|olbox.68|
|00000920| 6b 2e 34 69 2e 38 38 31 | 2e 70 72 65 22 2c 20 61 |k.4i.881|.pre", a|
|00000930| 6e 64 0d 22 56 69 64 65 | 6f 54 6f 6f 6c 62 6f 78 |nd."Vide|oToolbox|
|00000940| 2e 70 70 63 2e 70 72 65 | 22 2e 0d 0d 41 73 20 6f |.ppc.pre|"...As o|
|00000950| 66 20 4a 75 6e 65 20 31 | 34 2c 20 31 39 39 35 2c |f June 1|4, 1995,|
|00000960| 20 74 68 65 20 56 69 64 | 65 6f 54 6f 6f 6c 62 6f | the Vid|eoToolbo|
|00000970| 78 20 23 69 6e 63 6c 75 | 64 65 73 20 3c 61 73 73 |x #inclu|des <ass|
|00000980| 65 72 74 2e 68 3e 2c 20 | 6f 72 2c 20 69 66 20 4d |ert.h>, |or, if M|
|00000990| 41 54 4c 41 42 0d 69 73 | 20 74 72 75 65 2c 20 64 |ATLAB.is| true, d|
|000009a0| 65 66 69 6e 65 73 20 61 | 20 4d 41 54 4c 41 42 2d |efines a| MATLAB-|
|000009b0| 63 6f 6d 70 61 74 69 62 | 6c 65 20 76 65 72 73 69 |compatib|le versi|
|000009c0| 6f 6e 20 6f 66 20 61 73 | 73 65 72 74 28 29 2e 20 |on of as|sert(). |
|000009d0| 49 66 20 79 6f 75 72 20 | 73 6f 75 72 63 65 20 66 |If your |source f|
|000009e0| 69 6c 65 0d 23 69 6e 63 | 6c 75 64 65 73 20 3c 61 |ile.#inc|ludes <a|
|000009f0| 73 73 65 72 74 2e 68 3e | 20 74 68 65 6e 20 69 74 |ssert.h>| then it|
|00000a00| 20 77 69 6c 6c 20 62 65 | 20 69 6e 63 6c 75 64 65 | will be| include|
|00000a10| 64 20 61 67 61 69 6e 2c | 20 77 68 69 63 68 20 77 |d again,| which w|
|00000a20| 69 6c 6c 20 6f 62 76 69 | 61 74 65 20 74 68 65 20 |ill obvi|ate the |
|00000a30| 77 6f 72 6b 0d 64 6f 6e | 65 20 68 65 72 65 2c 20 |work.don|e here, |
|00000a40| 69 6e 63 6c 75 64 69 6e | 67 20 74 68 65 20 4d 41 |includin|g the MA|
|00000a50| 54 4c 41 42 20 63 6f 6d | 70 61 74 69 62 69 6c 69 |TLAB com|patibili|
|00000a60| 74 79 2e 20 46 6f 72 20 | 74 68 61 74 20 72 65 61 |ty. For |that rea|
|00000a70| 73 6f 6e 20 79 6f 75 20 | 73 68 6f 75 6c 64 20 4e |son you |should N|
|00000a80| 4f 54 0d 23 69 6e 63 6c | 75 64 65 20 3c 61 73 73 |OT.#incl|ude <ass|
|00000a90| 65 72 74 2e 68 3e 20 69 | 6e 20 79 6f 75 72 20 73 |ert.h> i|n your s|
|00000aa0| 6f 75 72 63 65 20 66 69 | 6c 65 73 2e 0d 0d 4d 41 |ource fi|les...MA|
|00000ab0| 43 5f 43 3a 0d 0d 44 65 | 66 69 6e 69 6e 67 20 74 |C_C:..De|fining t|
|00000ac0| 68 65 20 73 79 6d 62 6f | 6c 20 4d 41 43 5f 43 20 |he symbo|l MAC_C |
|00000ad0| 61 73 20 30 20 62 65 66 | 6f 72 65 20 74 68 69 73 |as 0 bef|ore this|
|00000ae0| 20 66 69 6c 65 20 69 73 | 20 63 6f 6d 70 69 6c 65 | file is| compile|
|00000af0| 64 20 77 69 6c 6c 20 6c | 65 61 76 65 20 6f 6e 6c |d will l|eave onl|
|00000b00| 79 20 74 68 65 20 0d 73 | 74 75 66 66 20 74 68 61 |y the .s|tuff tha|
|00000b10| 74 20 69 73 20 77 72 69 | 74 74 65 6e 20 69 6e 20 |t is wri|tten in |
|00000b20| 70 75 72 65 20 53 74 61 | 6e 64 61 72 64 20 43 2c |pure Sta|ndard C,|
|00000b30| 20 77 68 69 63 68 20 77 | 69 6c 6c 20 77 6f 72 6b | which w|ill work|
|00000b40| 20 6f 6e 20 61 6e 79 20 | 63 6f 6d 70 75 74 65 72 | on any |computer|
|00000b50| 2e 0d 0d 54 68 65 20 41 | 70 70 6c 65 20 4d 61 63 |...The A|pple Mac|
|00000b60| 69 6e 74 6f 73 68 20 68 | 65 61 64 65 72 20 66 69 |intosh h|eader fi|
|00000b70| 6c 65 73 20 75 73 65 20 | 73 6f 6d 65 20 65 78 74 |les use |some ext|
|00000b80| 65 6e 73 69 6f 6e 73 20 | 74 6f 20 43 20 74 68 61 |ensions |to C tha|
|00000b90| 74 20 61 72 65 20 6e 6f | 74 20 70 61 72 74 20 6f |t are no|t part o|
|00000ba0| 66 0d 53 74 61 6e 64 61 | 72 64 20 43 2c 20 65 2e |f.Standa|rd C, e.|
|00000bb0| 67 2e 20 22 70 61 73 63 | 61 6c 22 2c 20 22 73 68 |g. "pasc|al", "sh|
|00000bc0| 6f 72 74 20 64 6f 75 62 | 6c 65 22 2c 20 65 6e 75 |ort doub|le", enu|
|00000bd0| 6d 73 20 6c 61 72 67 65 | 72 20 74 68 61 6e 20 69 |ms large|r than i|
|00000be0| 6e 74 73 2c 20 61 6e 64 | 20 66 75 6e 63 74 69 6f |nts, and| functio|
|00000bf0| 6e 0d 70 72 6f 74 6f 74 | 79 70 65 73 20 74 68 61 |n.protot|ypes tha|
|00000c00| 74 20 73 70 65 63 69 66 | 79 20 61 62 73 6f 6c 75 |t specif|y absolu|
|00000c10| 74 65 20 61 64 64 72 65 | 73 73 65 73 2e 20 54 68 |te addre|sses. Th|
|00000c20| 65 73 65 20 6b 65 79 77 | 6f 72 64 73 20 61 6e 64 |ese keyw|ords and|
|00000c30| 20 63 6f 6e 73 74 72 75 | 63 74 69 6f 6e 73 0d 63 | constru|ctions.c|
|00000c40| 61 6e 6e 6f 74 20 62 65 | 20 63 6f 6d 70 69 6c 65 |annot be| compile|
|00000c50| 64 20 69 6e 20 53 74 61 | 6e 64 61 72 64 20 43 2e |d in Sta|ndard C.|
|00000c60| 20 54 68 65 20 6d 61 63 | 72 6f 20 4d 41 43 5f 43 | The mac|ro MAC_C|
|00000c70| 20 69 73 20 64 65 66 69 | 6e 65 64 20 61 73 20 74 | is defi|ned as t|
|00000c80| 72 75 65 2c 20 62 65 6c | 6f 77 2c 0d 6f 6e 6c 79 |rue, bel|ow,.only|
|00000c90| 20 6f 6e 20 4d 61 63 69 | 6e 74 6f 73 68 20 43 20 | on Maci|ntosh C |
|00000ca0| 63 6f 6d 70 69 6c 65 72 | 73 20 74 68 61 74 20 69 |compiler|s that i|
|00000cb0| 6e 63 6f 72 70 6f 72 61 | 74 65 20 74 68 65 73 65 |ncorpora|te these|
|00000cc0| 20 65 78 74 65 6e 73 69 | 6f 6e 73 2c 20 61 6e 64 | extensi|ons, and|
|00000cd0| 20 69 73 20 66 61 6c 73 | 65 0d 6f 74 68 65 72 77 | is fals|e.otherw|
|00000ce0| 69 73 65 2e 20 54 68 65 | 20 4d 41 43 5f 43 20 73 |ise. The| MAC_C s|
|00000cf0| 79 6d 62 6f 6c 20 69 73 | 20 75 73 65 64 20 74 6f |ymbol is| used to|
|00000d00| 20 70 72 65 76 65 6e 74 | 20 69 6e 63 6c 75 73 69 | prevent| inclusi|
|00000d10| 6f 6e 20 6f 66 20 61 6c | 6c 20 74 68 65 0d 4d 61 |on of al|l the.Ma|
|00000d20| 63 69 6e 74 6f 73 68 2d | 64 65 70 65 6e 64 65 6e |cintosh-|dependen|
|00000d30| 74 20 68 65 61 64 65 72 | 20 66 69 6c 65 73 20 61 |t header| files a|
|00000d40| 6e 64 20 70 72 6f 74 6f | 74 79 70 65 73 20 77 68 |nd proto|types wh|
|00000d50| 65 6e 20 74 68 65 20 63 | 6f 6d 70 69 6c 65 72 20 |en the c|ompiler |
|00000d60| 64 6f 65 73 6e 27 74 0d | 73 75 70 70 6f 72 74 20 |doesn't.|support |
|00000d70| 74 68 65 6d 2e 20 48 6f | 77 65 76 65 72 2c 20 6c |them. Ho|wever, l|
|00000d80| 61 63 6b 69 6e 67 20 61 | 6e 79 20 67 65 6e 65 72 |acking a|ny gener|
|00000d90| 61 6c 20 74 65 73 74 20 | 66 6f 72 20 74 68 65 73 |al test |for thes|
|00000da0| 65 20 65 78 74 65 6e 73 | 69 6f 6e 73 2c 20 61 20 |e extens|ions, a |
|00000db0| 74 65 73 74 0d 6d 75 73 | 74 20 62 65 20 61 64 64 |test.mus|t be add|
|00000dc0| 65 64 2c 20 62 65 6c 6f | 77 2c 20 66 6f 72 20 65 |ed, belo|w, for e|
|00000dd0| 61 63 68 20 6e 65 77 20 | 63 6f 6d 70 69 6c 65 72 |ach new |compiler|
|00000de0| 2e 20 41 74 20 70 72 65 | 73 65 6e 74 20 77 65 20 |. At pre|sent we |
|00000df0| 74 65 73 74 20 66 6f 72 | 20 53 79 6d 61 6e 74 65 |test for| Symante|
|00000e00| 63 20 43 0d 54 48 49 4e | 4b 20 43 2c 20 41 70 70 |c C.THIN|K C, App|
|00000e10| 6c 65 20 4d 50 57 20 43 | 2c 20 61 6e 64 20 4d 65 |le MPW C|, and Me|
|00000e20| 74 72 6f 77 65 72 6b 73 | 20 43 6f 64 65 57 61 72 |trowerks| CodeWar|
|00000e30| 72 69 6f 72 20 43 2e 0d | 0d 4d 41 54 4c 41 42 3a |rior C..|.MATLAB:|
|00000e40| 0d 0d 54 68 65 20 56 69 | 64 65 6f 54 6f 6f 6c 62 |..The Vi|deoToolb|
|00000e50| 6f 78 20 73 6f 75 72 63 | 65 73 20 63 61 6e 20 62 |ox sourc|es can b|
|00000e60| 65 20 6c 69 6e 6b 65 64 | 20 74 6f 20 63 72 65 61 |e linked| to crea|
|00000e70| 74 65 20 61 20 73 74 61 | 6e 64 2d 61 6c 6f 6e 65 |te a sta|nd-alone|
|00000e80| 20 43 20 61 70 70 6c 69 | 63 61 74 69 6f 6e 2c 20 | C appli|cation, |
|00000e90| 6f 72 0d 61 20 4d 41 54 | 4c 41 42 20 65 78 74 65 |or.a MAT|LAB exte|
|00000ea0| 72 6e 61 6c 20 63 6f 64 | 65 20 72 65 73 6f 75 72 |rnal cod|e resour|
|00000eb0| 63 65 20 28 61 20 22 4d | 45 58 22 20 66 69 6c 65 |ce (a "M|EX" file|
|00000ec0| 29 2c 20 74 6f 20 62 65 | 20 69 6e 76 6f 6b 65 64 |), to be| invoked|
|00000ed0| 20 62 79 20 74 79 70 69 | 6e 67 20 74 68 65 0d 66 | by typi|ng the.f|
|00000ee0| 75 6e 63 74 69 6f 6e 20 | 6e 61 6d 65 20 66 72 6f |unction |name fro|
|00000ef0| 6d 20 77 69 74 68 69 6e | 20 4d 41 54 4c 41 42 2e |m within| MATLAB.|
|00000f00| 20 49 6e 20 74 68 61 74 | 20 63 61 73 65 20 77 65 | In that| case we|
|00000f10| 20 63 61 6c 6c 20 74 68 | 65 20 54 48 49 4e 4b 20 | call th|e THINK |
|00000f20| 43 20 70 72 6f 6a 65 63 | 74 20 61 0d 22 4d 41 54 |C projec|t a."MAT|
|00000f30| 4c 41 42 20 70 72 6f 6a | 65 63 74 22 2e 20 41 20 |LAB proj|ect". A |
|00000f40| 4d 41 54 4c 41 42 20 70 | 72 6f 6a 65 63 74 20 6d |MATLAB p|roject m|
|00000f50| 75 73 74 20 23 64 65 66 | 69 6e 65 20 74 68 65 20 |ust #def|ine the |
|00000f60| 73 79 6d 62 6f 6c 20 4d | 41 54 4c 41 42 20 61 73 |symbol M|ATLAB as|
|00000f70| 20 74 72 75 65 20 66 6f | 72 0d 65 76 65 72 79 20 | true fo|r.every |
|00000f80| 43 20 66 69 6c 65 2c 20 | 6d 75 73 74 20 23 69 6e |C file, |must #in|
|00000f90| 63 6c 75 64 65 20 74 68 | 65 20 56 69 64 65 6f 54 |clude th|e VideoT|
|00000fa0| 6f 6f 6c 62 6f 78 2e 68 | 20 68 65 61 64 65 72 20 |oolbox.h| header |
|00000fb0| 61 74 20 74 68 65 20 62 | 65 67 69 6e 6e 69 6e 67 |at the b|eginning|
|00000fc0| 20 6f 66 20 65 76 65 72 | 79 0d 43 20 66 69 6c 65 | of ever|y.C file|
|00000fd0| 2c 20 61 6e 64 20 6d 75 | 73 74 20 23 69 6e 63 6c |, and mu|st #incl|
|00000fe0| 75 64 65 20 4d 41 54 4c | 41 42 4d 61 69 6e 2e 68 |ude MATL|ABMain.h|
|00000ff0| 20 69 6e 20 74 68 65 20 | 6d 61 69 6e 20 43 20 66 | in the |main C f|
|00001000| 69 6c 65 2e 0d 0d 59 6f | 75 20 6d 75 73 74 20 68 |ile...Yo|u must h|
|00001010| 61 76 65 20 74 68 65 20 | 66 69 6c 65 20 22 63 6d |ave the |file "cm|
|00001020| 65 78 2e 68 22 20 69 6e | 20 6f 72 64 65 72 20 74 |ex.h" in| order t|
|00001030| 6f 20 63 6f 6d 70 69 6c | 65 20 74 68 69 73 20 66 |o compil|e this f|
|00001040| 69 6c 65 20 77 68 65 6e | 20 22 4d 41 54 4c 41 42 |ile when| "MATLAB|
|00001050| 22 20 69 73 20 74 72 75 | 65 2e 0d 22 63 6d 65 78 |" is tru|e.."cmex|
|00001060| 2e 68 22 20 69 73 20 64 | 69 73 74 72 69 62 75 74 |.h" is d|istribut|
|00001070| 65 64 20 62 79 20 4d 61 | 74 68 57 6f 72 6b 73 20 |ed by Ma|thWorks |
|00001080| 61 73 20 70 61 72 74 20 | 6f 66 20 4d 41 54 4c 41 |as part |of MATLA|
|00001090| 42 2e 0d 0d 44 6f 6e 27 | 74 20 23 64 65 66 69 6e |B...Don'|t #defin|
|000010a0| 65 20 4d 41 54 4c 41 42 | 20 77 69 74 68 69 6e 20 |e MATLAB| within |
|000010b0| 79 6f 75 72 20 43 20 66 | 69 6c 65 3b 20 75 73 65 |your C f|ile; use|
|000010c0| 20 74 68 65 20 45 64 69 | 74 3a 4f 70 74 69 6f 6e | the Edi|t:Option|
|000010d0| 73 3a 54 48 49 4e 4b 20 | 43 3a 50 72 65 66 69 78 |s:THINK |C:Prefix|
|000010e0| 0d 77 69 6e 64 6f 77 20 | 69 6e 73 74 65 61 64 2e |.window |instead.|
|000010f0| 20 45 2e 67 2e 20 79 6f | 75 20 63 6f 75 6c 64 20 | E.g. yo|u could |
|00001100| 74 79 70 65 0d 09 23 64 | 65 66 69 6e 65 20 4d 41 |type..#d|efine MA|
|00001110| 54 4c 41 42 20 31 0d 69 | 6e 74 6f 20 74 68 65 20 |TLAB 1.i|nto the |
|00001120| 50 72 65 66 69 78 20 77 | 69 6e 64 6f 77 2c 20 6f |Prefix w|indow, o|
|00001130| 72 2c 20 6d 6f 72 65 20 | 63 6f 6e 76 65 6e 69 65 |r, more |convenie|
|00001140| 6e 74 6c 79 20 28 62 65 | 63 61 75 73 65 20 69 74 |ntly (be|cause it|
|00001150| 20 73 70 65 65 64 73 20 | 75 70 20 79 6f 75 72 0d | speeds |up your.|
|00001160| 63 6f 6d 70 69 6c 61 74 | 69 6f 6e 73 20 65 6e 6f |compilat|ions eno|
|00001170| 72 6d 6f 75 73 6c 79 29 | 2c 20 74 79 70 65 0d 09 |rmously)|, type..|
|00001180| 23 69 6e 63 6c 75 64 65 | 20 22 56 69 64 65 6f 54 |#include| "VideoT|
|00001190| 6f 6f 6c 62 6f 78 4d 41 | 54 4c 41 42 2e 70 72 65 |oolboxMA|TLAB.pre|
|000011a0| 22 0d 53 65 65 20 56 69 | 64 65 6f 54 6f 6f 6c 62 |".See Vi|deoToolb|
|000011b0| 6f 78 4d 41 54 4c 41 42 | 2e 63 20 66 6f 72 20 69 |oxMATLAB|.c for i|
|000011c0| 6e 73 74 72 75 63 74 69 | 6f 6e 73 2e 0d 0d 54 68 |nstructi|ons...Th|
|000011d0| 65 20 4d 41 54 4c 41 42 | 4d 61 69 6e 2e 68 20 68 |e MATLAB|Main.h h|
|000011e0| 65 61 64 65 72 20 61 6c | 6c 6f 63 61 74 65 73 20 |eader al|locates |
|000011f0| 73 70 61 63 65 20 66 6f | 72 20 51 75 69 63 6b 44 |space fo|r QuickD|
|00001200| 72 61 77 20 67 6c 6f 62 | 61 6c 73 20 66 6f 72 20 |raw glob|als for |
|00001210| 75 73 65 20 62 79 20 54 | 48 49 4e 4b 20 43 0d 4d |use by T|HINK C.M|
|00001220| 41 54 4c 41 42 20 70 72 | 6f 6a 65 63 74 73 2e 20 |ATLAB pr|ojects. |
|00001230| 49 74 20 73 68 6f 75 6c | 64 20 62 65 20 23 69 6e |It shoul|d be #in|
|00001240| 63 6c 75 64 65 64 20 69 | 6e 20 74 68 65 20 6d 61 |cluded i|n the ma|
|00001250| 69 6e 20 43 20 66 69 6c | 65 20 6f 66 20 65 61 63 |in C fil|e of eac|
|00001260| 68 20 54 48 49 4e 4b 20 | 43 0d 4d 41 54 4c 41 42 |h THINK |C.MATLAB|
|00001270| 20 70 72 6f 6a 65 63 74 | 2c 20 69 2e 65 2e 20 69 | project|, i.e. i|
|00001280| 6e 20 74 68 65 20 43 20 | 66 69 6c 65 20 74 68 61 |n the C |file tha|
|00001290| 74 20 63 6f 6e 74 61 69 | 6e 73 20 22 6d 61 69 6e |t contai|ns "main|
|000012a0| 22 20 6f 72 20 22 75 73 | 65 72 5f 66 63 6e 22 2e |" or "us|er_fcn".|
|000012b0| 20 49 74 20 6d 75 73 74 | 0d 62 65 20 69 6e 63 6c | It must|.be incl|
|000012c0| 75 64 65 64 20 69 6e 20 | 65 78 61 63 74 6c 79 20 |uded in |exactly |
|000012d0| 6f 6e 65 20 73 6f 75 72 | 63 65 20 66 69 6c 65 20 |one sour|ce file |
|000012e0| 6f 66 20 65 61 63 68 20 | 70 72 6f 6a 65 63 74 2c |of each |project,|
|000012f0| 20 61 73 20 74 68 65 20 | 54 48 49 4e 4b 20 43 20 | as the |THINK C |
|00001300| 4c 69 6e 6b 65 72 0d 77 | 69 6c 6c 20 6f 74 68 65 |Linker.w|ill othe|
|00001310| 72 77 69 73 65 20 63 6f | 6d 70 6c 61 69 6e 2e 0d |rwise co|mplain..|
|00001320| 0d 64 67 70 20 26 20 64 | 68 62 2e 0d 43 6f 70 79 |.dgp & d|hb..Copy|
|00001330| 72 69 67 68 74 20 31 39 | 38 39 2d 31 39 39 34 20 |right 19|89-1994 |
|00001340| a9 20 44 65 6e 69 73 20 | 47 2e 20 50 65 6c 6c 69 |. Denis |G. Pelli|
|00001350| 0d 0d 48 49 53 54 4f 52 | 59 3a 20 28 6f 6d 69 74 |..HISTOR|Y: (omit|
|00001360| 74 69 6e 67 20 63 68 61 | 6e 67 65 73 20 64 6f 63 |ting cha|nges doc|
|00001370| 75 6d 65 6e 74 65 64 20 | 69 6e 20 43 20 66 69 6c |umented |in C fil|
|00001380| 65 73 29 0d 32 2f 32 30 | 2f 39 33 20 64 68 62 09 |es).2/20|/93 dhb.|
|00001390| 41 64 64 65 64 20 76 61 | 72 69 6f 75 73 20 63 6f |Added va|rious co|
|000013a0| 6d 6d 6f 6e 6c 79 20 75 | 73 65 64 20 68 65 61 64 |mmonly u|sed head|
|000013b0| 65 72 73 2e 20 20 0d 09 | 09 09 52 65 73 74 72 75 |ers. ..|..Restru|
|000013c0| 63 74 75 72 65 64 20 73 | 6f 20 74 68 61 74 20 6f |ctured s|o that o|
|000013d0| 6e 6c 79 20 56 69 64 65 | 6f 54 6f 6f 6c 62 6f 78 |nly Vide|oToolbox|
|000013e0| 2e 68 20 68 61 73 20 74 | 6f 20 62 65 20 69 6e 63 |.h has t|o be inc|
|000013f0| 6c 75 64 65 64 2c 0d 09 | 09 09 77 68 65 74 68 65 |luded,..|..whethe|
|00001400| 72 20 6f 6e 65 20 69 73 | 20 63 72 65 61 74 69 6e |r one is| creatin|
|00001410| 67 20 73 74 61 6e 64 2d | 61 6c 6f 6e 65 20 54 48 |g stand-|alone TH|
|00001420| 49 4e 4b 20 43 20 6f 72 | 20 63 6f 64 65 20 72 65 |INK C or| code re|
|00001430| 73 6f 75 72 63 65 73 0d | 09 09 09 74 6f 20 62 65 |sources.|...to be|
|00001440| 20 63 61 6c 6c 65 64 20 | 62 79 20 4d 41 54 4c 41 | called |by MATLA|
|00001450| 42 2e 20 45 76 65 72 79 | 74 68 69 6e 67 20 74 68 |B. Every|thing th|
|00001460| 61 74 20 63 61 72 65 73 | 20 69 73 20 70 72 6f 70 |at cares| is prop|
|00001470| 65 72 6c 79 20 63 6f 6e | 64 69 74 69 6f 6e 65 64 |erly con|ditioned|
|00001480| 0d 09 09 09 62 79 20 74 | 68 65 20 73 79 6d 62 6f |....by t|he symbo|
|00001490| 6c 20 4d 41 54 4c 41 42 | 2e 0d 37 2f 39 2f 39 33 |l MATLAB|..7/9/93|
|000014a0| 09 64 67 70 09 43 68 61 | 6e 67 65 64 20 6f 75 72 |.dgp.Cha|nged our|
|000014b0| 20 63 6f 6e 76 65 6e 74 | 69 6f 6e 20 66 6f 72 20 | convent|ion for |
|000014c0| 74 68 65 20 4d 41 54 4c | 41 42 20 73 79 6d 62 6f |the MATL|AB symbo|
|000014d0| 6c 2c 20 64 65 66 69 6e | 69 6e 67 20 69 74 20 61 |l, defin|ing it a|
|000014e0| 73 0d 09 09 09 31 20 6f | 72 20 30 20 69 6e 73 74 |s....1 o|r 0 inst|
|000014f0| 65 61 64 20 6f 66 20 64 | 65 66 69 6e 69 6e 67 20 |ead of d|efining |
|00001500| 6f 72 20 6c 65 61 76 69 | 6e 67 20 75 6e 64 65 66 |or leavi|ng undef|
|00001510| 69 6e 65 64 2e 20 54 68 | 65 20 61 64 76 61 6e 74 |ined. Th|e advant|
|00001520| 61 67 65 20 6f 66 0d 09 | 09 09 74 68 69 73 20 61 |age of..|..this a|
|00001530| 70 70 72 6f 61 63 68 20 | 69 73 20 74 68 61 74 20 |pproach |is that |
|00001540| 22 4d 41 54 4c 41 42 22 | 20 63 61 6e 20 6e 6f 77 |"MATLAB"| can now|
|00001550| 20 62 65 20 75 73 65 64 | 20 61 73 20 61 6e 20 61 | be used| as an a|
|00001560| 72 67 75 6d 65 6e 74 20 | 69 6e 20 61 6e 0d 09 09 |rgument |in an...|
|00001570| 09 6f 72 64 69 6e 61 72 | 79 20 69 66 20 73 74 61 |.ordinar|y if sta|
|00001580| 74 65 6d 65 6e 74 2c 20 | 77 68 69 63 68 20 69 73 |tement, |which is|
|00001590| 20 6d 75 63 68 20 6d 6f | 72 65 20 72 65 61 64 61 | much mo|re reada|
|000015a0| 62 6c 65 20 74 68 61 6e | 20 23 69 66 2e 0d 38 2f |ble than| #if..8/|
|000015b0| 32 31 2f 39 33 09 64 68 | 62 09 41 64 64 65 64 20 |21/93.dh|b.Added |
|000015c0| 75 6e 64 65 66 73 20 69 | 6e 20 23 69 66 20 4d 41 |undefs i|n #if MA|
|000015d0| 54 4c 41 42 20 73 6f 20 | 74 68 61 74 20 6d 65 6d |TLAB so |that mem|
|000015e0| 6f 72 79 20 61 6c 6c 6f | 63 61 74 69 6f 6e 20 67 |ory allo|cation g|
|000015f0| 6f 65 73 20 74 68 72 6f | 75 67 68 20 54 48 49 4e |oes thro|ugh THIN|
|00001600| 4b 20 43 20 0d 09 09 09 | 6c 69 62 72 61 72 79 2c |K C ....|library,|
|00001610| 20 6e 6f 74 20 61 73 20 | 63 61 6c 6c 62 61 63 6b | not as |callback|
|00001620| 2e 20 43 61 6c 6c 62 61 | 63 6b 73 20 77 6f 75 6c |. Callba|cks woul|
|00001630| 64 20 62 65 20 4f 4b 20 | 65 78 63 65 70 74 20 74 |d be OK |except t|
|00001640| 68 61 74 20 74 68 65 20 | 4d 61 74 68 77 6f 72 6b |hat the |Mathwork|
|00001650| 73 20 0d 09 09 09 66 6f | 72 67 6f 74 20 74 6f 20 |s ....fo|rgot to |
|00001660| 67 69 76 65 20 75 73 20 | 6f 6e 65 20 66 6f 72 20 |give us |one for |
|00001670| 72 65 61 6c 6c 6f 63 2e | 20 54 68 69 73 20 6c 65 |realloc.| This le|
|00001680| 61 64 73 20 74 6f 20 6d | 69 78 69 6e 67 20 6d 65 |ads to m|ixing me|
|00001690| 6d 6f 72 79 20 6d 61 6e | 61 67 65 72 73 0d 20 09 |mory man|agers. .|
|000016a0| 09 09 6f 6e 20 74 68 65 | 20 73 61 6d 65 20 70 6f |..on the| same po|
|000016b0| 69 6e 74 65 72 73 20 2d | 2d 20 62 61 64 20 62 61 |inters -|- bad ba|
|000016c0| 64 20 62 61 64 2e 0d 39 | 2f 32 2f 39 33 09 64 68 |d bad..9|/2/93.dh|
|000016d0| 62 09 63 6f 6d 6d 65 6e | 74 65 64 20 6f 75 74 20 |b.commen|ted out |
|000016e0| 23 69 6e 63 6c 75 64 65 | 20 3c 54 72 61 6e 73 6c |#include| <Transl|
|000016f0| 61 74 65 4c 69 6e 65 66 | 65 65 64 73 2e 68 3e 20 |ateLinef|eeds.h> |
|00001700| 73 69 6e 63 65 20 69 74 | 27 73 0d 09 09 09 6e 6f |since it|'s....no|
|00001710| 74 20 70 72 65 73 65 6e | 74 6c 79 20 63 6f 6d 70 |t presen|tly comp|
|00001720| 61 74 69 62 6c 65 20 77 | 69 74 68 20 4d 41 54 4c |atible w|ith MATL|
|00001730| 41 42 2e 0d 39 2f 32 2f | 39 33 09 64 67 70 09 4d |AB..9/2/|93.dgp.M|
|00001740| 6f 76 65 64 20 74 68 65 | 20 4e 4c 20 61 6e 64 20 |oved the| NL and |
|00001750| 4e 45 57 4c 49 4e 45 20 | 6d 61 63 72 6f 73 20 66 |NEWLINE |macros f|
|00001760| 72 6f 6d 20 41 73 73 69 | 67 6e 2e 63 20 69 6e 74 |rom Assi|gn.c int|
|00001770| 6f 20 74 68 69 73 20 66 | 69 6c 65 2e 0d 39 2f 38 |o this f|ile..9/8|
|00001780| 2f 39 33 09 64 67 70 09 | 4d 65 6e 74 69 6f 6e 20 |/93.dgp.|Mention |
|00001790| 56 69 64 65 6f 54 6f 6f | 6c 62 6f 78 2e 63 2e 0d |VideoToo|lbox.c..|
|000017a0| 39 2f 31 31 2f 39 33 09 | 64 68 62 2c 64 67 70 09 |9/11/93.|dhb,dgp.|
|000017b0| 44 65 66 69 6e 65 20 53 | 54 44 49 4f 5f 49 4e 54 |Define S|TDIO_INT|
|000017c0| 20 61 6e 64 20 53 54 44 | 49 4f 5f 44 4f 55 42 4c | and STD|IO_DOUBL|
|000017d0| 45 2e 0d 39 2f 31 32 2f | 39 33 09 64 68 62 09 43 |E..9/12/|93.dhb.C|
|000017e0| 68 61 6e 67 65 20 53 54 | 44 49 4f 5f 2e 2e 2e 20 |hange ST|DIO_... |
|000017f0| 74 6f 20 50 52 49 4e 54 | 46 5f 2e 2e 2e 20 61 6e |to PRINT|F_... an|
|00001800| 64 20 53 43 41 4e 46 5f | 2e 2e 2e 0d 09 09 09 49 |d SCANF_|.......I|
|00001810| 6e 73 65 72 74 20 63 6f | 6e 64 69 74 69 6f 6e 61 |nsert co|nditiona|
|00001820| 6c 20 66 6f 72 20 4d 41 | 54 4c 41 42 20 33 2e 35 |l for MA|TLAB 3.5|
|00001830| 20 76 73 2e 20 34 2e 78 | 0d 39 2f 31 34 2f 39 33 | vs. 4.x|.9/14/93|
|00001840| 09 64 68 62 09 43 6f 6e | 64 69 74 69 6f 6e 61 6c |.dhb.Con|ditional|
|00001850| 20 66 6f 72 20 4d 41 54 | 4c 41 42 20 63 68 61 6e | for MAT|LAB chan|
|00001860| 67 65 64 20 74 6f 20 6d | 61 6b 65 20 73 79 6d 62 |ged to m|ake symb|
|00001870| 6f 6c 20 6d 61 74 63 68 | 20 6d 61 6a 6f 72 20 76 |ol match| major v|
|00001880| 65 72 73 69 6f 6e 20 6e | 75 6d 62 65 72 2e 0d 09 |ersion n|umber...|
|00001890| 09 09 52 65 6d 6f 76 65 | 64 20 74 72 61 63 65 73 |..Remove|d traces|
|000018a0| 20 6f 66 20 6f 6c 64 20 | 74 72 79 69 6e 67 20 74 | of old |trying t|
|000018b0| 6f 20 66 6f 72 63 65 20 | 34 20 62 79 74 65 20 69 |o force |4 byte i|
|000018c0| 6e 74 73 20 66 6f 72 20 | 4d 41 54 4c 41 42 2e 0d |nts for |MATLAB..|
|000018d0| 39 2f 31 34 2f 39 33 09 | 64 67 70 09 4d 6f 76 65 |9/14/93.|dgp.Move|
|000018e0| 64 20 75 70 20 69 6e 63 | 6c 75 73 69 6f 6e 20 6f |d up inc|lusion o|
|000018f0| 66 20 51 75 69 63 6b 44 | 72 61 77 2e 68 20 62 65 |f QuickD|raw.h be|
|00001900| 66 6f 72 65 20 4d 41 54 | 4c 41 42 20 73 74 75 66 |fore MAT|LAB stuf|
|00001910| 66 2c 20 73 69 6e 63 65 | 20 63 6d 65 78 2e 68 0d |f, since| cmex.h.|
|00001920| 09 09 09 72 65 71 75 69 | 72 65 73 20 69 74 2e 20 |...requi|res it. |
|00001930| 46 69 78 65 64 20 74 79 | 70 6f 2c 20 63 68 61 6e |Fixed ty|po, chan|
|00001940| 67 69 6e 67 20 22 23 65 | 6c 73 65 69 66 22 20 74 |ging "#e|lseif" t|
|00001950| 6f 20 22 23 65 6c 69 66 | 22 2e 0d 39 2f 31 35 2f |o "#elif|"..9/15/|
|00001960| 39 33 09 64 67 70 09 45 | 64 69 74 65 64 20 74 68 |93.dgp.E|dited th|
|00001970| 65 20 63 6f 6d 6d 65 6e | 74 73 20 61 62 6f 76 65 |e commen|ts above|
|00001980| 2c 20 72 65 66 65 72 72 | 69 6e 67 20 74 6f 20 56 |, referr|ing to V|
|00001990| 69 64 65 6f 54 6f 6f 6c | 62 6f 78 2e 63 20 61 6e |ideoTool|box.c an|
|000019a0| 64 20 74 68 65 20 6e 65 | 77 20 0d 09 09 09 56 69 |d the ne|w ....Vi|
|000019b0| 64 65 6f 54 6f 6f 6c 62 | 6f 78 4d 41 54 4c 41 42 |deoToolb|oxMATLAB|
|000019c0| 2e 63 2e 0d 39 2f 31 36 | 2f 39 33 09 64 67 70 09 |.c..9/16|/93.dgp.|
|000019d0| 41 64 64 65 64 20 63 6f | 6e 74 65 6e 74 73 20 6f |Added co|ntents o|
|000019e0| 66 20 66 6f 72 6d 65 72 | 20 41 73 73 69 67 6e 2e |f former| Assign.|
|000019f0| 68 2e 0d 09 09 09 44 65 | 66 69 6e 65 64 20 4d 41 |h.....De|fined MA|
|00001a00| 43 5f 43 20 73 6f 20 74 | 68 61 74 20 74 68 65 20 |C_C so t|hat the |
|00001a10| 56 69 64 65 6f 54 6f 6f | 6c 62 6f 78 2e 68 20 68 |VideoToo|lbox.h h|
|00001a20| 65 61 64 65 72 20 6d 61 | 79 20 62 65 20 75 73 65 |eader ma|y be use|
|00001a30| 64 20 77 69 74 68 0d 09 | 09 09 53 74 61 6e 64 61 |d with..|..Standa|
|00001a40| 72 64 20 43 2e 0d 39 2f | 31 36 2f 39 33 09 64 68 |rd C..9/|16/93.dh|
|00001a50| 62 20 52 65 6d 6f 76 65 | 64 20 70 72 6f 74 6f 74 |b Remove|d protot|
|00001a60| 79 70 65 20 66 6f 72 20 | 6f 62 73 6f 6c 65 74 65 |ype for |obsolete|
|00001a70| 20 47 65 74 44 61 74 65 | 54 69 6d 65 53 74 72 69 | GetDate|TimeStri|
|00001a80| 6e 67 2e 0d 31 30 2f 32 | 2f 39 33 09 64 67 70 09 |ng..10/2|/93.dgp.|
|00001a90| 41 64 64 65 64 20 23 69 | 6e 63 6c 75 64 65 20 3c |Added #i|nclude <|
|00001aa0| 45 72 72 6f 72 73 2e 68 | 3e 2e 0d 31 32 2f 31 2f |Errors.h|>..12/1/|
|00001ab0| 39 33 20 64 67 70 20 4e | 6f 77 20 61 6c 77 61 79 |93 dgp N|ow alway|
|00001ac0| 73 20 77 72 69 74 65 20 | 22 4d 41 54 4c 41 42 22 |s write |"MATLAB"|
|00001ad0| 20 69 6e 20 61 6c 6c 20 | 63 61 70 73 2c 20 73 69 | in all |caps, si|
|00001ae0| 6e 63 65 20 74 68 61 74 | 27 73 20 74 68 65 20 74 |nce that|'s the t|
|00001af0| 72 61 64 65 6d 61 72 6b | 65 64 20 6e 61 6d 65 2e |rademark|ed name.|
|00001b00| 0d 31 32 2f 31 36 2f 39 | 33 20 64 68 62 20 53 6f |.12/16/9|3 dhb So|
|00001b10| 6d 65 77 68 65 72 65 20 | 74 68 69 6e 67 73 20 67 |mewhere |things g|
|00001b20| 6f 74 20 6d 75 6e 67 65 | 64 2e 20 20 43 6f 6e 64 |ot munge|d. Cond|
|00001b30| 69 74 69 6f 6e 61 6c 20 | 66 6f 72 20 4d 41 54 4c |itional |for MATL|
|00001b40| 41 42 20 76 65 72 73 69 | 6f 6e 20 61 70 70 65 61 |AB versi|on appea|
|00001b50| 72 65 64 0d 20 20 20 20 | 20 20 20 20 20 20 20 62 |red. | b|
|00001b60| 65 66 6f 72 65 20 69 6e | 63 6c 75 73 69 6f 6e 20 |efore in|clusion |
|00001b70| 6f 66 20 63 6d 65 78 2c | 20 77 68 69 63 68 20 77 |of cmex,| which w|
|00001b80| 6f 6e 27 74 20 77 6f 72 | 6b 2e 20 20 49 20 66 69 |on't wor|k. I fi|
|00001b90| 78 65 64 20 74 68 65 20 | 6f 72 64 65 72 2e 0d 31 |xed the |order..1|
|00001ba0| 32 2f 31 36 2f 39 33 20 | 64 68 62 20 43 6f 6d 6d |2/16/93 |dhb Comm|
|00001bb0| 65 6e 74 65 64 20 6f 75 | 74 20 69 6e 63 6c 75 73 |ented ou|t inclus|
|00001bc0| 69 6f 6e 20 6f 66 20 54 | 72 61 6e 73 6c 61 74 65 |ion of T|ranslate|
|00001bd0| 4c 69 6e 65 46 65 65 64 | 73 2e 68 20 64 6f 77 6e |LineFeed|s.h down|
|00001be0| 20 62 65 6c 6f 77 2e 20 | 20 54 68 69 73 0d 20 20 | below. | This. |
|00001bf0| 20 20 20 20 20 20 20 20 | 20 67 65 6e 65 72 61 74 | | generat|
|00001c00| 65 73 20 61 20 6c 69 6e | 6b 20 65 72 72 6f 72 20 |es a lin|k error |
|00001c10| 66 72 6f 6d 20 4d 41 54 | 4c 41 42 2e 0d 31 32 2f |from MAT|LAB..12/|
|00001c20| 32 39 2f 39 33 20 64 67 | 70 20 61 64 64 65 64 20 |29/93 dg|p added |
|00001c30| 23 69 6e 63 6c 75 64 65 | 20 3c 50 61 63 6b 61 67 |#include| <Packag|
|00001c40| 65 73 2e 68 3e 0d 36 2f | 31 32 2f 39 34 20 20 64 |es.h>.6/|12/94 d|
|00001c50| 67 70 20 61 64 64 65 64 | 20 64 65 66 69 6e 69 74 |gp added| definit|
|00001c60| 69 6f 6e 20 6f 66 20 41 | 70 70 6c 65 27 73 20 6e |ion of A|pple's n|
|00001c70| 65 77 20 42 6c 6f 63 6b | 4d 6f 76 65 44 61 74 61 |ew Block|MoveData|
|00001c80| 2c 20 66 6f 72 20 63 6f | 6d 70 61 74 69 62 69 6c |, for co|mpatibil|
|00001c90| 69 74 79 20 77 69 74 68 | 0d 09 09 09 41 70 70 6c |ity with|....Appl|
|00001ca0| 65 27 73 20 6f 6c 64 20 | 70 72 65 2d 55 6e 69 76 |e's old |pre-Univ|
|00001cb0| 65 72 73 61 6c 20 68 65 | 61 64 65 72 20 66 69 6c |ersal he|ader fil|
|00001cc0| 65 73 2e 0d 36 2f 31 32 | 2f 39 34 09 64 67 70 20 |es..6/12|/94.dgp |
|00001cd0| 23 69 6e 63 6c 75 64 65 | 20 53 74 72 69 6e 67 73 |#include| Strings|
|00001ce0| 2e 68 20 69 66 20 55 6e | 69 76 65 72 73 61 6c 20 |.h if Un|iversal |
|00001cf0| 68 65 61 64 65 72 20 66 | 69 6c 65 73 20 61 72 65 |header f|iles are|
|00001d00| 20 75 73 65 64 2e 0d 37 | 2f 32 38 2f 39 34 20 64 | used..7|/28/94 d|
|00001d10| 67 70 20 41 64 64 65 64 | 20 74 65 73 74 20 66 6f |gp Added| test fo|
|00001d20| 72 20 4d 65 74 72 6f 77 | 65 72 6b 73 20 43 6f 64 |r Metrow|erks Cod|
|00001d30| 65 57 61 72 72 69 6f 72 | 20 43 2e 0d 39 2f 32 2f |eWarrior| C..9/2/|
|00001d40| 39 34 09 64 67 70 20 23 | 69 6e 63 6c 75 64 65 20 |94.dgp #|include |
|00001d50| 4d 61 63 4d 65 6d 6f 72 | 79 2e 68 0d 39 2f 35 2f |MacMemor|y.h.9/5/|
|00001d60| 39 34 09 64 67 70 20 63 | 68 61 6e 67 65 64 20 22 |94.dgp c|hanged "|
|00001d70| 69 6e 74 22 20 74 6f 20 | 22 73 68 6f 72 74 20 69 |int" to |"short i|
|00001d80| 6e 74 22 20 69 6e 20 64 | 65 66 69 6e 69 74 69 6f |nt" in d|efinitio|
|00001d90| 6e 73 20 6f 66 20 50 52 | 49 4e 54 46 5f 49 4e 54 |ns of PR|INTF_INT|
|00001da0| 20 61 6e 64 20 53 43 41 | 4e 46 5f 49 4e 54 20 66 | and SCA|NF_INT f|
|00001db0| 6f 72 0d 09 09 09 4d 41 | 54 4c 41 42 20 34 2e 20 |or....MA|TLAB 4. |
|00001dc0| 54 68 69 73 20 69 73 20 | 62 61 73 65 64 20 6f 6e |This is |based on|
|00001dd0| 20 63 6f 6d 6d 6f 6e 20 | 73 65 6e 73 65 2c 20 6e | common |sense, n|
|00001de0| 6f 74 20 74 65 73 74 69 | 6e 67 20 6f 72 20 64 65 |ot testi|ng or de|
|00001df0| 74 61 69 6c 65 64 20 6b | 6e 6f 77 6c 65 64 67 65 |tailed k|nowledge|
|00001e00| 2e 0d 33 2f 33 31 2f 39 | 35 09 64 67 70 09 41 73 |..3/31/9|5.dgp.As|
|00001e10| 20 61 20 67 65 73 74 75 | 72 65 20 6f 66 20 73 75 | a gestu|re of su|
|00001e20| 70 70 6f 72 74 20 66 6f | 72 20 53 79 6d 61 6e 74 |pport fo|r Symant|
|00001e30| 65 63 20 54 48 49 4e 4b | 20 43 20 38 2c 20 6e 6f |ec THINK| C 8, no|
|00001e40| 77 20 64 65 66 69 6e 65 | 20 54 48 49 4e 4b 5f 43 |w define| THINK_C|
|00001e50| 2e 0d 35 2f 32 36 2f 39 | 35 20 64 67 70 20 46 6f |..5/26/9|5 dgp Fo|
|00001e60| 72 6d 65 72 6c 79 20 68 | 65 61 64 65 72 20 66 69 |rmerly h|eader fi|
|00001e70| 6c 65 73 20 77 68 6f 73 | 65 20 70 72 65 63 6f 6d |les whos|e precom|
|00001e80| 70 69 6c 61 74 69 6f 6e | 20 64 65 70 65 6e 64 73 |pilation| depends|
|00001e90| 20 6f 6e 20 74 68 65 20 | 6d 63 36 38 38 38 31 20 | on the |mc68881 |
|00001ea0| 6f 72 20 0d 09 09 6d 63 | 36 38 30 32 30 20 54 48 |or ...mc|68020 TH|
|00001eb0| 49 4e 4b 20 43 20 63 6f | 6d 70 69 6c 65 72 20 6f |INK C co|mpiler o|
|00001ec0| 70 74 69 6f 6e 73 20 28 | 69 2e 65 2e 20 6d 61 74 |ptions (|i.e. mat|
|00001ed0| 68 2e 68 20 61 6e 64 20 | 6d 63 36 38 38 38 31 2e |h.h and |mc68881.|
|00001ee0| 68 29 20 77 65 72 65 20 | 6f 6d 69 74 74 65 64 20 |h) were |omitted |
|00001ef0| 0d 09 09 66 72 6f 6d 20 | 56 69 64 65 6f 54 6f 6f |...from |VideoToo|
|00001f00| 6c 62 6f 78 2e 68 20 73 | 6f 20 74 68 61 74 20 74 |lbox.h s|o that t|
|00001f10| 68 65 20 72 65 73 75 6c | 74 69 6e 67 20 70 72 65 |he resul|ting pre|
|00001f20| 63 6f 6d 70 69 6c 65 64 | 20 68 65 61 64 65 72 20 |compiled| header |
|00001f30| 66 69 6c 65 20 63 6f 75 | 6c 64 20 62 65 20 0d 09 |file cou|ld be ..|
|00001f40| 09 75 73 65 64 20 69 6e | 20 70 72 6f 6a 65 63 74 |.used in| project|
|00001f50| 73 20 72 65 67 61 72 64 | 6c 65 73 73 20 6f 66 20 |s regard|less of |
|00001f60| 74 68 6f 73 65 20 6f 70 | 74 69 6f 6e 73 2e 20 48 |those op|tions. H|
|00001f70| 6f 77 65 76 65 72 2c 20 | 66 6f 72 20 4d 65 74 72 |owever, |for Metr|
|00001f80| 6f 77 65 72 6b 73 20 43 | 6f 64 65 57 61 72 72 69 |owerks C|odeWarri|
|00001f90| 6f 72 0d 09 09 74 68 65 | 72 65 27 73 20 6e 6f 20 |or...the|re's no |
|00001fa0| 61 64 76 61 6e 74 61 67 | 65 20 74 6f 20 6f 6d 69 |advantag|e to omi|
|00001fb0| 74 74 69 6e 67 20 74 68 | 6f 73 65 20 68 65 61 64 |tting th|ose head|
|00001fc0| 65 72 73 2c 20 61 6e 64 | 20 61 20 73 69 67 6e 69 |ers, and| a signi|
|00001fd0| 66 69 63 61 6e 74 20 69 | 6e 63 72 65 61 73 65 20 |ficant i|ncrease |
|00001fe0| 69 6e 0d 09 09 63 6f 6d | 70 69 6c 65 20 74 69 6d |in...com|pile tim|
|00001ff0| 65 2c 20 61 73 20 66 70 | 2e 68 20 69 73 20 72 65 |e, as fp|.h is re|
|00002000| 63 6f 6d 70 69 6c 65 64 | 20 66 6f 72 20 65 61 63 |compiled| for eac|
|00002010| 68 20 66 69 6c 65 2e 20 | 53 69 6e 63 65 20 49 27 |h file. |Since I'|
|00002020| 76 65 20 73 77 69 74 63 | 68 20 74 6f 0d 09 09 43 |ve switc|h to...C|
|00002030| 6f 64 65 57 61 72 72 69 | 6f 72 2c 20 61 6e 64 20 |odeWarri|or, and |
|00002040| 65 78 70 65 63 74 20 6d | 6f 73 74 20 6f 74 68 65 |expect m|ost othe|
|00002050| 72 20 75 73 65 72 73 20 | 74 6f 20 73 77 69 74 63 |r users |to switc|
|00002060| 68 20 61 73 20 77 65 6c | 6c 2c 20 56 69 64 65 6f |h as wel|l, Video|
|00002070| 54 6f 6f 6c 62 6f 78 2e | 68 20 6e 6f 77 0d 09 09 |Toolbox.|h now...|
|00002080| 69 6e 63 6c 75 64 65 73 | 20 6d 61 74 68 2e 68 20 |includes| math.h |
|00002090| 6f 72 20 66 70 2e 68 2e | 0d 35 2f 32 37 2f 39 35 |or fp.h.|.5/27/95|
|000020a0| 20 64 67 70 20 72 65 6d | 6f 76 65 64 20 66 70 2e | dgp rem|oved fp.|
|000020b0| 63 20 70 72 6f 74 6f 74 | 79 70 65 73 20 62 65 63 |c protot|ypes bec|
|000020c0| 61 75 73 65 20 41 70 70 | 6c 65 27 73 20 66 70 2e |ause App|le's fp.|
|000020d0| 68 20 6e 6f 77 20 73 75 | 70 70 6f 72 74 73 20 62 |h now su|pports b|
|000020e0| 6f 74 68 20 36 38 6b 20 | 61 6e 64 20 70 70 63 2e |oth 68k |and ppc.|
|000020f0| 0d 36 2f 36 2f 39 35 20 | 64 67 70 20 64 69 73 63 |.6/6/95 |dgp disc|
|00002100| 61 72 64 65 64 20 61 6c | 6c 20 72 65 66 65 72 65 |arded al|l refere|
|00002110| 6e 63 65 73 20 74 6f 20 | 54 72 61 6e 73 6c 61 74 |nces to |Translat|
|00002120| 65 4c 69 6e 65 66 65 65 | 64 73 2e 63 20 61 6e 64 |eLinefee|ds.c and|
|00002130| 20 54 72 61 6e 73 6c 61 | 74 65 4c 69 6e 65 66 65 | Transla|teLinefe|
|00002140| 65 64 73 2e 68 2c 20 73 | 69 6e 63 65 0d 09 09 49 |eds.h, s|ince...I|
|00002150| 20 6e 65 76 65 72 20 67 | 6f 74 20 74 68 65 6d 20 | never g|ot them |
|00002160| 74 6f 20 77 6f 72 6b 20 | 70 72 6f 70 65 72 6c 79 |to work |properly|
|00002170| 2c 20 61 6e 64 20 49 20 | 64 6f 6e 27 74 20 74 68 |, and I |don't th|
|00002180| 69 6e 6b 20 74 68 65 79 | 27 72 65 20 6e 65 65 64 |ink they|'re need|
|00002190| 65 64 20 77 69 74 68 20 | 4d 65 74 72 6f 77 65 72 |ed with |Metrower|
|000021a0| 6b 73 0d 09 09 43 6f 64 | 65 57 61 72 72 69 6f 72 |ks...Cod|eWarrior|
|000021b0| 2e 0d 36 2f 38 2f 39 35 | 20 64 67 70 20 4d 61 64 |..6/8/95| dgp Mad|
|000021c0| 65 20 73 75 72 65 20 74 | 68 61 74 20 74 68 65 20 |e sure t|hat the |
|000021d0| 4d 41 54 4c 41 42 20 73 | 74 72 75 63 74 20 22 4d |MATLAB s|truct "M|
|000021e0| 61 74 72 69 78 22 20 69 | 73 20 61 6c 77 61 79 73 |atrix" i|s always|
|000021f0| 20 6e 61 74 69 76 65 20 | 61 6c 69 67 6e 65 64 2e | native |aligned.|
|00002200| 0d 36 2f 31 33 2f 39 35 | 20 64 67 70 20 64 65 66 |.6/13/95| dgp def|
|00002210| 69 6e 65 20 47 45 4e 45 | 52 41 54 49 4e 47 36 38 |ine GENE|RATING68|
|00002220| 4b 2c 20 47 45 4e 45 52 | 41 54 49 4e 47 50 4f 57 |K, GENER|ATINGPOW|
|00002230| 45 52 50 43 2c 20 61 6e | 64 20 47 45 4e 45 52 41 |ERPC, an|d GENERA|
|00002240| 54 49 4e 47 36 38 38 38 | 31 20 69 66 20 6e 6f 74 |TING6888|1 if not|
|00002250| 20 61 6c 72 65 61 64 79 | 0d 09 09 64 65 66 69 6e | already|...defin|
|00002260| 65 64 20 28 61 73 20 69 | 6e 20 41 70 70 6c 65 27 |ed (as i|n Apple'|
|00002270| 73 20 6c 61 74 65 73 74 | 20 75 6e 69 76 65 72 73 |s latest| univers|
|00002280| 61 6c 20 68 65 61 64 65 | 72 73 29 2e 20 44 65 66 |al heade|rs). Def|
|00002290| 69 6e 65 20 47 45 4e 45 | 52 41 54 49 4e 47 36 38 |ine GENE|RATING68|
|000022a0| 30 32 30 2e 0d 36 2f 31 | 34 2f 39 35 09 64 68 62 |020..6/1|4/95.dhb|
|000022b0| 20 26 20 64 67 70 20 72 | 65 64 65 66 69 6e 65 20 | & dgp r|edefine |
|000022c0| 74 68 65 20 61 73 73 65 | 72 74 28 29 20 6d 61 63 |the asse|rt() mac|
|000022d0| 72 6f 2c 20 72 65 64 69 | 72 65 63 74 69 6e 67 20 |ro, redi|recting |
|000022e0| 69 74 20 74 6f 20 50 72 | 69 6e 74 66 45 78 69 74 |it to Pr|intfExit|
|000022f0| 2c 20 77 68 69 63 68 0d | 09 09 69 6e 20 74 75 72 |, which.|..in tur|
|00002300| 6e 20 75 73 65 73 20 6d | 65 78 5f 65 72 72 6f 72 |n uses m|ex_error|
|00002310| 28 29 20 74 6f 20 72 65 | 70 6f 72 74 20 74 68 65 |() to re|port the|
|00002320| 20 65 72 72 6f 72 2e 20 | 54 68 69 73 20 69 73 20 | error. |This is |
|00002330| 6e 65 65 64 65 64 20 74 | 6f 20 67 65 74 20 4d 45 |needed t|o get ME|
|00002340| 58 20 66 69 6c 65 73 0d | 09 09 74 6f 20 6c 69 6e |X files.|..to lin|
|00002350| 6b 20 70 72 6f 70 65 72 | 6c 79 2e 0d 36 2f 31 36 |k proper|ly..6/16|
|00002360| 2f 39 35 09 64 68 62 20 | 46 69 78 65 64 20 4d 41 |/95.dhb |Fixed MA|
|00002370| 54 4c 41 42 27 73 20 53 | 43 41 4e 46 5f 49 4e 54 |TLAB's S|CANF_INT|
|00002380| 20 65 74 63 2e 20 66 6f | 72 20 5f 5f 4d 57 45 52 | etc. fo|r __MWER|
|00002390| 4b 53 5f 5f 2e 0d 36 2f | 31 36 2f 39 35 20 64 67 |KS__..6/|16/95 dg|
|000023a0| 70 20 6d 6f 76 65 64 20 | 74 68 65 20 64 65 66 69 |p moved |the defi|
|000023b0| 6e 69 74 69 6f 6e 73 20 | 6f 66 20 47 45 4e 45 52 |nitions |of GENER|
|000023c0| 41 54 49 4e 47 36 38 4b | 20 74 6f 20 74 68 65 20 |ATING68K| to the |
|000023d0| 74 6f 70 20 6f 66 20 74 | 68 69 73 20 66 69 6c 65 |top of t|his file|
|000023e0| 2c 20 73 6f 20 74 68 61 | 74 0d 09 09 74 68 65 20 |, so tha|t...the |
|000023f0| 4d 41 54 4c 41 42 20 63 | 6f 6e 64 69 74 69 6f 6e |MATLAB c|ondition|
|00002400| 61 6c 73 20 63 61 6e 20 | 75 73 65 20 74 68 65 6d |als can |use them|
|00002410| 2e 0d 36 2f 31 36 2f 39 | 35 09 64 68 62 09 26 20 |..6/16/9|5.dhb.& |
|00002420| 64 67 70 20 6e 6f 77 20 | 23 69 6e 63 6c 75 64 65 |dgp now |#include|
|00002430| 20 3c 61 73 73 65 72 74 | 2e 68 3e 2c 20 75 6e 6c | <assert|.h>, unl|
|00002440| 65 73 73 20 4d 41 54 4c | 41 42 20 69 73 20 64 65 |ess MATL|AB is de|
|00002450| 66 69 6e 65 64 2c 20 69 | 6e 20 77 68 69 63 68 20 |fined, i|n which |
|00002460| 63 61 73 65 0d 09 09 77 | 65 20 64 65 66 69 6e 65 |case...w|e define|
|00002470| 20 61 20 4d 41 54 4c 41 | 42 2d 63 6f 6d 70 61 74 | a MATLA|B-compat|
|00002480| 69 62 6c 65 20 76 65 72 | 73 69 6f 6e 20 6f 66 20 |ible ver|sion of |
|00002490| 74 68 65 20 61 73 73 65 | 72 74 20 6d 61 63 72 6f |the asse|rt macro|
|000024a0| 2e 20 4a 75 73 74 20 69 | 6e 20 63 61 73 65 2c 0d |. Just i|n case,.|
|000024b0| 09 09 6c 65 61 76 65 20 | 4e 44 45 42 55 47 20 64 |..leave |NDEBUG d|
|000024c0| 65 66 69 6e 65 64 20 74 | 6f 20 64 69 73 61 62 6c |efined t|o disabl|
|000024d0| 65 20 74 68 65 20 73 74 | 61 6e 64 61 72 64 20 61 |e the st|andard a|
|000024e0| 73 73 65 72 74 20 6d 61 | 63 72 6f 20 77 68 69 63 |ssert ma|cro whic|
|000024f0| 68 20 6d 61 79 20 62 65 | 0d 09 09 62 72 6f 75 67 |h may be|...broug|
|00002500| 68 74 20 69 6e 20 69 66 | 20 74 68 65 20 75 73 65 |ht in if| the use|
|00002510| 72 27 73 20 73 6f 75 72 | 63 65 20 66 69 6c 65 73 |r's sour|ce files|
|00002520| 20 23 69 6e 63 6c 75 64 | 65 20 3c 61 73 73 65 72 | #includ|e <asser|
|00002530| 74 2e 68 3e 2e 0d 36 2f | 31 36 2f 39 35 09 64 68 |t.h>..6/|16/95.dh|
|00002540| 62 09 46 69 78 65 64 20 | 6c 6f 6e 67 73 74 61 6e |b.Fixed |longstan|
|00002550| 64 69 6e 67 20 62 75 67 | 20 28 69 6e 20 53 43 41 |ding bug| (in SCA|
|00002560| 4e 46 5f 49 4e 54 3f 3f | 29 2e 0d 36 2f 32 33 2f |NF_INT??|)..6/23/|
|00002570| 39 35 09 64 68 62 09 49 | 6e 63 6c 75 64 65 20 70 |95.dhb.I|nclude p|
|00002580| 72 6f 74 6f 74 79 70 65 | 73 20 66 6f 72 20 41 66 |rototype|s for Af|
|00002590| 74 65 72 44 61 72 6b 2e | 63 20 61 6e 64 20 49 73 |terDark.|c and Is|
|000025a0| 46 69 6c 65 53 68 61 72 | 69 6e 67 4f 6e 2e 63 2e |FileShar|ingOn.c.|
|000025b0| 0d 37 2f 31 39 2f 39 35 | 20 64 67 70 20 41 64 64 |.7/19/95| dgp Add|
|000025c0| 65 64 20 63 68 61 6e 67 | 65 73 20 73 75 67 67 65 |ed chang|es sugge|
|000025d0| 73 74 65 64 20 62 79 20 | 53 74 65 66 61 6e 20 54 |sted by |Stefan T|
|000025e0| 72 65 75 65 2c 20 73 74 | 72 65 75 65 40 62 63 6d |reue, st|reue@bcm|
|000025f0| 2e 74 6d 63 2e 65 64 75 | 2c 20 66 6f 72 20 63 6f |.tmc.edu|, for co|
|00002600| 6d 70 61 74 69 62 69 6c | 69 74 79 0d 09 09 77 69 |mpatibil|ity...wi|
|00002610| 74 68 20 53 79 6d 61 6e | 74 65 63 20 43 2e 20 45 |th Syman|tec C. E|
|00002620| 6c 69 6d 69 6e 61 74 65 | 64 20 75 73 65 20 6f 66 |liminate|d use of|
|00002630| 20 2f 2f 2d 73 74 79 6c | 65 20 63 6f 6d 6d 65 6e | //-styl|e commen|
|00002640| 74 73 2e 20 4e 6f 77 20 | 69 6e 63 6c 75 64 65 20 |ts. Now |include |
|00002650| 6d 61 74 68 2e 68 0d 09 | 09 77 68 65 6e 20 63 6f |math.h..|.when co|
|00002660| 6d 70 69 6c 69 6e 67 20 | 66 6f 72 20 53 74 61 6e |mpiling |for Stan|
|00002670| 64 61 72 64 20 43 2c 20 | 69 2e 65 2e 20 4d 41 43 |dard C, |i.e. MAC|
|00002680| 5f 43 20 69 73 20 66 61 | 6c 73 65 2e 0d 38 2f 31 |_C is fa|lse..8/1|
|00002690| 30 2f 39 35 20 64 67 70 | 20 49 6e 63 6c 75 64 65 |0/95 dgp| Include|
|000026a0| 20 4d 61 63 4d 65 6d 6f | 72 79 2e 68 20 4f 4e 4c | MacMemo|ry.h ONL|
|000026b0| 59 20 66 6f 72 20 54 48 | 49 4e 4b 20 43 2c 20 6e |Y for TH|INK C, n|
|000026c0| 6f 74 20 66 6f 72 20 53 | 79 6d 61 6e 74 65 63 20 |ot for S|ymantec |
|000026d0| 43 2c 20 73 69 6e 63 65 | 20 49 20 64 6f 6e 27 74 |C, since| I don't|
|000026e0| 0d 09 09 68 61 76 65 20 | 61 6e 79 20 72 65 61 73 |...have |any reas|
|000026f0| 6f 6e 20 74 6f 20 74 68 | 69 6e 6b 20 74 68 61 74 |on to th|ink that|
|00002700| 20 53 79 6d 61 6e 74 65 | 63 20 43 20 6d 65 6d 6f | Symante|c C memo|
|00002710| 72 79 20 6d 61 6e 61 67 | 65 6d 65 6e 74 20 69 73 |ry manag|ement is|
|00002720| 20 62 61 64 2e 0d 38 2f | 31 33 2f 39 35 20 64 67 | bad..8/|13/95 dg|
|00002730| 70 20 52 65 6d 6f 76 65 | 64 20 64 65 66 69 6e 69 |p Remove|d defini|
|00002740| 74 69 6f 6e 20 6f 66 20 | 54 48 49 4e 4b 5f 43 20 |tion of |THINK_C |
|00002750| 66 6f 72 20 53 59 4d 41 | 4e 54 45 43 5f 43 2e 20 |for SYMA|NTEC_C. |
|00002760| 49 74 20 73 65 65 6d 73 | 20 62 65 74 74 65 72 20 |It seems| better |
|00002770| 74 6f 20 6c 65 61 76 65 | 0d 09 09 74 68 65 20 63 |to leave|...the c|
|00002780| 6f 6d 70 69 6c 65 72 27 | 73 20 6d 61 63 72 6f 73 |ompiler'|s macros|
|00002790| 20 61 6c 6f 6e 65 2e 20 | 43 68 61 6e 67 65 64 20 | alone. |Changed |
|000027a0| 63 6f 6e 64 69 74 69 6f | 6e 61 6c 73 20 74 68 72 |conditio|nals thr|
|000027b0| 6f 75 67 68 6f 75 74 20 | 74 68 65 20 56 69 64 65 |oughout |the Vide|
|000027c0| 6f 54 6f 6f 6c 62 6f 78 | 0d 09 09 74 6f 20 64 65 |oToolbox|...to de|
|000027d0| 61 6c 20 77 69 74 68 20 | 61 6c 6c 20 74 68 65 20 |al with |all the |
|000027e0| 73 70 65 63 69 61 6c 20 | 63 61 73 65 73 3a 20 54 |special |cases: T|
|000027f0| 48 49 4e 4b 5f 43 2c 20 | 54 48 49 4e 4b 5f 43 50 |HINK_C, |THINK_CP|
|00002800| 4c 55 53 2c 20 61 6e 64 | 20 53 59 4d 41 4e 54 45 |LUS, and| SYMANTE|
|00002810| 43 5f 43 2e 0d 33 2f 35 | 2f 39 36 09 64 68 62 20 |C_C..3/5|/96.dhb |
|00002820| 41 64 64 20 63 6f 6e 64 | 69 74 69 6f 6e 61 6c 20 |Add cond|itional |
|00002830| 74 6f 20 70 72 65 76 65 | 6e 74 20 69 6e 63 6c 75 |to preve|nt inclu|
|00002840| 73 69 6f 6e 20 6f 66 20 | 3c 66 70 2e 68 3e 20 61 |sion of |<fp.h> a|
|00002850| 6e 64 20 69 6e 73 74 65 | 61 64 20 69 6e 63 6c 75 |nd inste|ad inclu|
|00002860| 64 65 20 3c 6d 61 74 68 | 2e 68 3e 0d 09 09 77 68 |de <math|.h>...wh|
|00002870| 65 6e 20 54 48 49 4e 4b | 5f 43 20 69 73 20 74 72 |en THINK|_C is tr|
|00002880| 75 65 2e 20 20 54 68 69 | 73 20 69 73 20 6e 65 65 |ue. Thi|s is nee|
|00002890| 64 65 64 20 74 6f 20 63 | 6f 6d 70 69 6c 65 20 75 |ded to c|ompile u|
|000028a0| 6e 64 65 72 20 54 48 49 | 4e 4b 5f 43 20 38 2e 20 |nder THI|NK_C 8. |
|000028b0| 20 49 20 73 75 73 70 65 | 63 74 0d 09 09 74 68 61 | I suspe|ct...tha|
|000028c0| 74 20 74 68 69 73 20 75 | 73 65 64 20 74 6f 20 77 |t this u|sed to w|
|000028d0| 6f 72 6b 20 62 65 63 61 | 75 73 65 20 74 68 65 20 |ork beca|use the |
|000028e0| 75 6e 69 76 65 72 73 61 | 6c 20 68 65 61 64 65 72 |universa|l header|
|000028f0| 73 20 76 61 72 69 61 62 | 6c 65 20 77 61 73 20 3c |s variab|le was <|
|00002900| 20 32 2e 0d 34 2f 31 2f | 39 36 09 64 67 70 20 72 | 2..4/1/|96.dgp r|
|00002910| 65 6d 6f 76 65 64 20 22 | 4d 41 43 5f 43 22 20 72 |emoved "|MAC_C" r|
|00002920| 65 71 75 69 72 65 6d 65 | 6e 74 20 66 6f 72 20 69 |equireme|nt for i|
|00002930| 6e 63 6c 75 73 69 6f 6e | 20 6f 66 20 66 70 2e 68 |nclusion| of fp.h|
|00002940| 2e 20 54 72 69 65 64 20 | 74 6f 20 6d 61 6b 65 20 |. Tried |to make |
|00002950| 56 69 64 65 6f 54 6f 6f | 6c 62 6f 78 2e 68 0d 09 |VideoToo|lbox.h..|
|00002960| 09 6d 6f 72 65 20 63 6f | 6e 73 69 73 74 65 6e 74 |.more co|nsistent|
|00002970| 20 77 69 74 68 20 71 5f | 69 6e 63 6c 75 64 65 2e | with q_|include.|
|00002980| 68 2c 20 73 6f 20 62 6f | 74 68 20 77 69 6c 6c 20 |h, so bo|th will |
|00002990| 77 6f 72 6b 20 73 65 70 | 61 72 61 74 65 6c 79 20 |work sep|arately |
|000029a0| 6f 72 20 74 6f 67 65 74 | 68 65 72 2c 20 69 6e 0d |or toget|her, in.|
|000029b0| 09 09 65 69 74 68 65 72 | 20 6f 72 64 65 72 2c 20 |..either| order, |
|000029c0| 62 75 74 20 49 20 68 61 | 76 65 6e 27 74 20 63 68 |but I ha|ven't ch|
|000029d0| 65 63 6b 65 64 20 77 68 | 65 74 68 65 72 20 49 20 |ecked wh|ether I |
|000029e0| 73 75 63 63 65 65 64 65 | 64 2e 0d 2a 2f 0d 23 70 |succeede|d..*/.#p|
|000029f0| 72 61 67 6d 61 20 6f 6e | 63 65 09 09 09 2f 2a 20 |ragma on|ce.../* |
|00002a00| 20 73 75 70 70 72 65 73 | 73 20 6d 75 6c 74 69 70 | suppres|s multip|
|00002a10| 6c 65 20 69 6e 63 6c 75 | 73 69 6f 6e 73 20 6f 66 |le inclu|sions of|
|00002a20| 20 74 68 69 73 20 66 69 | 6c 65 20 2a 2f 0d 23 69 | this fi|le */.#i|
|00002a30| 66 6e 64 65 66 20 5f 56 | 49 44 45 4f 54 4f 4f 4c |fndef _V|IDEOTOOL|
|00002a40| 42 4f 58 5f 09 2f 2a 20 | 20 73 75 70 70 72 65 73 |BOX_./* | suppres|
|00002a50| 73 20 6d 75 6c 74 69 70 | 6c 65 20 69 6e 63 6c 75 |s multip|le inclu|
|00002a60| 73 69 6f 6e 73 20 6f 66 | 20 74 68 69 73 20 66 69 |sions of| this fi|
|00002a70| 6c 65 20 2a 2f 0d 23 64 | 65 66 69 6e 65 20 5f 56 |le */.#d|efine _V|
|00002a80| 49 44 45 4f 54 4f 4f 4c | 42 4f 58 5f 0d 2f 2a 0d |IDEOTOOL|BOX_./*.|
|00002a90| 48 65 61 64 65 72 20 66 | 69 6c 65 73 20 74 68 61 |Header f|iles tha|
|00002aa0| 74 20 61 72 65 20 72 65 | 71 75 69 72 65 64 20 66 |t are re|quired f|
|00002ab0| 6f 72 20 73 75 63 63 65 | 73 73 66 75 6c 20 63 6f |or succe|ssful co|
|00002ac0| 6d 70 69 6c 61 74 69 6f | 6e 20 6f 66 20 74 68 65 |mpilatio|n of the|
|00002ad0| 20 72 65 73 74 20 6f 66 | 20 74 68 69 73 0d 66 69 | rest of| this.fi|
|00002ae0| 6c 65 20 61 72 65 20 6d | 61 72 6b 65 64 20 22 72 |le are m|arked "r|
|00002af0| 65 71 75 69 72 65 64 22 | 2e 0d 2a 2f 0d 23 69 66 |equired"|..*/.#if|
|00002b00| 20 21 64 65 66 69 6e 65 | 64 28 4d 41 43 5f 43 29 | !define|d(MAC_C)|
|00002b10| 0d 09 23 69 66 20 54 48 | 49 4e 4b 5f 43 09 7c 7c |..#if TH|INK_C.|||
|00002b20| 20 54 48 49 4e 4b 5f 43 | 50 4c 55 53 20 7c 7c 20 | THINK_C|PLUS || |
|00002b30| 53 59 4d 41 4e 54 45 43 | 5f 43 09 09 09 09 09 09 |SYMANTEC|_C......|
|00002b40| 09 5c 0d 09 09 7c 7c 20 | 61 70 70 6c 65 63 09 09 |.\...|| |applec..|
|00002b50| 09 2f 2a 20 4d 50 57 20 | 43 2c 20 70 72 65 73 75 |./* MPW |C, presu|
|00002b60| 6d 61 62 6c 79 20 77 69 | 74 68 20 4d 61 63 20 65 |mably wi|th Mac e|
|00002b70| 78 74 65 6e 73 69 6f 6e | 73 20 2a 2f 09 5c 0d 09 |xtension|s */.\..|
|00002b80| 09 7c 7c 20 5f 5f 4d 57 | 45 52 4b 53 5f 5f 09 09 |.|| __MW|ERKS__..|
|00002b90| 2f 2a 20 4d 65 74 72 6f | 77 65 72 6b 73 20 43 6f |/* Metro|werks Co|
|00002ba0| 64 65 57 61 72 72 69 6f | 72 20 43 2c 20 22 20 2a |deWarrio|r C, " *|
|00002bb0| 2f 0d 09 09 2f 2a 20 53 | 65 74 20 4d 41 43 5f 43 |/.../* S|et MAC_C|
|00002bc0| 20 74 6f 20 74 72 75 65 | 20 6f 6e 6c 79 20 69 66 | to true| only if|
|00002bd0| 20 74 68 65 20 22 70 61 | 73 63 61 6c 22 20 6b 65 | the "pa|scal" ke|
|00002be0| 79 77 6f 72 64 20 69 73 | 20 61 6c 6c 6f 77 65 64 |yword is| allowed|
|00002bf0| 2e 20 2a 2f 0d 09 09 23 | 69 66 20 54 48 49 4e 4b |. */...#|if THINK|
|00002c00| 5f 43 20 26 26 20 21 53 | 59 4d 41 4e 54 45 43 5f |_C && !S|YMANTEC_|
|00002c10| 43 0d 09 09 09 23 69 66 | 20 21 5f 5f 6f 70 74 69 |C....#if| !__opti|
|00002c20| 6f 6e 28 74 68 69 6e 6b | 63 29 0d 09 09 09 09 23 |on(think|c).....#|
|00002c30| 64 65 66 69 6e 65 20 4d | 41 43 5f 43 20 30 09 2f |define M|AC_C 0./|
|00002c40| 2a 20 53 74 61 6e 64 61 | 72 64 20 43 20 2a 2f 0d |* Standa|rd C */.|
|00002c50| 09 09 09 23 65 6e 64 69 | 66 0d 09 09 23 65 6e 64 |...#endi|f...#end|
|00002c60| 69 66 0d 09 09 23 69 66 | 20 53 59 4d 41 4e 54 45 |if...#if| SYMANTE|
|00002c70| 43 5f 43 0d 09 09 09 23 | 69 66 20 5f 5f 6f 70 74 |C_C....#|if __opt|
|00002c80| 69 6f 6e 28 61 6e 73 69 | 5f 73 74 72 69 63 74 29 |ion(ansi|_strict)|
|00002c90| 0d 09 09 09 09 23 64 65 | 66 69 6e 65 20 4d 41 43 |.....#de|fine MAC|
|00002ca0| 5f 43 20 30 09 2f 2a 20 | 53 74 61 6e 64 61 72 64 |_C 0./* |Standard|
|00002cb0| 20 43 20 2a 2f 0d 09 09 | 09 23 65 6e 64 69 66 0d | C */...|.#endif.|
|00002cc0| 09 09 23 65 6e 64 69 66 | 0d 09 09 23 69 66 20 5f |..#endif|...#if _|
|00002cd0| 5f 4d 57 45 52 4b 53 5f | 5f 0d 09 09 09 23 69 66 |_MWERKS_|_....#if|
|00002ce0| 20 5f 5f 6f 70 74 69 6f | 6e 28 41 4e 53 49 5f 73 | __optio|n(ANSI_s|
|00002cf0| 74 72 69 63 74 29 20 7c | 7c 20 5f 5f 6f 70 74 69 |trict) ||| __opti|
|00002d00| 6f 6e 28 6f 6e 6c 79 5f | 73 74 64 5f 6b 65 79 77 |on(only_|std_keyw|
|00002d10| 6f 72 64 73 29 0d 09 09 | 09 09 23 64 65 66 69 6e |ords)...|..#defin|
|00002d20| 65 20 4d 41 43 5f 43 20 | 30 09 2f 2a 20 53 74 61 |e MAC_C |0./* Sta|
|00002d30| 6e 64 61 72 64 20 43 20 | 2a 2f 0d 09 09 09 23 65 |ndard C |*/....#e|
|00002d40| 6e 64 69 66 0d 09 09 23 | 65 6e 64 69 66 0d 09 09 |ndif...#|endif...|
|00002d50| 23 69 66 20 21 64 65 66 | 69 6e 65 64 28 4d 41 43 |#if !def|ined(MAC|
|00002d60| 5f 43 29 0d 09 09 09 23 | 64 65 66 69 6e 65 20 4d |_C)....#|define M|
|00002d70| 41 43 5f 43 20 31 09 2f | 2a 20 61 6c 6c 6f 77 20 |AC_C 1./|* allow |
|00002d80| 4d 61 63 20 43 20 65 78 | 74 65 6e 73 69 6f 6e 73 |Mac C ex|tensions|
|00002d90| 3a 20 22 70 61 73 63 61 | 6c 22 2c 20 65 74 63 2e |: "pasca|l", etc.|
|00002da0| 20 2a 2f 0d 09 09 23 65 | 6e 64 69 66 0d 09 23 65 | */...#e|ndif..#e|
|00002db0| 6c 73 65 0d 09 09 23 64 | 65 66 69 6e 65 20 4d 41 |lse...#d|efine MA|
|00002dc0| 43 5f 43 20 30 09 09 2f | 2a 20 53 74 61 6e 64 61 |C_C 0../|* Standa|
|00002dd0| 72 64 20 43 20 2a 2f 0d | 09 23 65 6e 64 69 66 0d |rd C */.|.#endif.|
|00002de0| 23 65 6e 64 69 66 0d 23 | 69 66 6e 64 65 66 20 53 |#endif.#|ifndef S|
|00002df0| 48 4f 52 54 5f 44 4f 55 | 42 4c 45 5f 4f 4b 0d 09 |HORT_DOU|BLE_OK..|
|00002e00| 23 69 66 20 53 59 4d 41 | 4e 54 45 43 5f 43 0d 09 |#if SYMA|NTEC_C..|
|00002e10| 09 23 64 65 66 69 6e 65 | 20 53 48 4f 52 54 5f 44 |.#define| SHORT_D|
|00002e20| 4f 55 42 4c 45 5f 4f 4b | 20 30 09 09 2f 2a 20 22 |OUBLE_OK| 0../* "|
|00002e30| 73 68 6f 72 74 20 64 6f | 75 62 6c 65 22 20 6e 6f |short do|uble" no|
|00002e40| 74 20 73 75 70 70 6f 72 | 74 65 64 20 62 79 20 53 |t suppor|ted by S|
|00002e50| 79 6d 61 6e 74 65 63 20 | 43 20 2a 2f 0d 09 23 65 |ymantec |C */..#e|
|00002e60| 6c 73 65 0d 09 09 23 64 | 65 66 69 6e 65 20 53 48 |lse...#d|efine SH|
|00002e70| 4f 52 54 5f 44 4f 55 42 | 4c 45 5f 4f 4b 20 4d 41 |ORT_DOUB|LE_OK MA|
|00002e80| 43 5f 43 09 2f 2a 20 22 | 73 68 6f 72 74 20 64 6f |C_C./* "|short do|
|00002e90| 75 62 6c 65 22 20 6e 6f | 74 20 61 6c 6c 6f 77 65 |uble" no|t allowe|
|00002ea0| 64 20 62 79 20 53 74 61 | 6e 64 61 72 64 20 43 20 |d by Sta|ndard C |
|00002eb0| 2a 2f 0d 09 23 65 6e 64 | 69 66 0d 23 65 6e 64 69 |*/..#end|if.#endi|
|00002ec0| 66 0d 23 69 6e 63 6c 75 | 64 65 20 3c 73 74 64 69 |f.#inclu|de <stdi|
|00002ed0| 6f 2e 68 3e 09 09 09 2f | 2a 20 20 72 65 71 75 69 |o.h>.../|* requi|
|00002ee0| 72 65 64 20 2a 2f 0d 23 | 69 6e 63 6c 75 64 65 20 |red */.#|include |
|00002ef0| 3c 73 74 64 6c 69 62 2e | 68 3e 0d 23 69 66 20 4d |<stdlib.|h>.#if M|
|00002f00| 41 43 5f 43 0d 09 23 69 | 6e 63 6c 75 64 65 20 3c |AC_C..#i|nclude <|
|00002f10| 51 75 69 63 6b 64 72 61 | 77 2e 68 3e 09 2f 2a 20 |Quickdra|w.h>./* |
|00002f20| 20 72 65 71 75 69 72 65 | 64 20 2a 2f 0d 23 65 6e | require|d */.#en|
|00002f30| 64 69 66 0d 2f 2a 0d 54 | 68 65 20 69 6e 63 6c 75 |dif./*.T|he inclu|
|00002f40| 73 69 6f 6e 2c 20 61 62 | 6f 76 65 2c 20 6f 66 20 |sion, ab|ove, of |
|00002f50| 51 75 69 63 6b 64 72 61 | 77 2e 68 20 77 69 6c 6c |Quickdra|w.h will|
|00002f60| 20 72 65 73 75 6c 74 20 | 69 6e 20 74 68 65 20 69 | result |in the i|
|00002f70| 6e 63 6c 75 73 69 6f 6e | 20 6f 66 20 4d 69 78 65 |nclusion| of Mixe|
|00002f80| 64 4d 6f 64 65 2e 68 0d | 6f 6e 6c 79 20 69 66 20 |dMode.h.|only if |
|00002f90| 74 68 65 20 55 6e 69 76 | 65 72 73 61 6c 20 48 65 |the Univ|ersal He|
|00002fa0| 61 64 65 72 73 20 61 72 | 65 20 75 73 65 64 2c 20 |aders ar|e used, |
|00002fb0| 73 69 6e 63 65 20 74 68 | 65 20 55 6e 69 76 65 72 |since th|e Univer|
|00002fc0| 73 61 6c 20 48 65 61 64 | 65 72 73 20 61 6e 64 20 |sal Head|ers and |
|00002fd0| 74 68 65 20 4d 69 78 65 | 64 0d 4d 6f 64 65 20 4d |the Mixe|d.Mode M|
|00002fe0| 61 6e 61 67 65 72 20 61 | 72 65 20 62 6f 74 68 20 |anager a|re both |
|00002ff0| 6e 65 77 2c 20 70 72 6f | 76 69 64 69 6e 67 20 75 |new, pro|viding u|
|00003000| 6e 69 76 65 72 73 61 6c | 20 73 75 70 70 6f 72 74 |niversal| support|
|00003010| 20 66 6f 72 20 36 38 6b | 20 61 6e 64 20 70 70 63 | for 68k| and ppc|
|00003020| 20 4d 61 63 73 2e 0d 2a | 2f 0d 23 69 66 20 64 65 | Macs..*|/.#if de|
|00003030| 66 69 6e 65 64 28 5f 5f | 4d 49 58 45 44 4d 4f 44 |fined(__|MIXEDMOD|
|00003040| 45 5f 5f 29 0d 09 23 69 | 66 20 64 65 66 69 6e 65 |E__)..#i|f define|
|00003050| 64 28 47 45 4e 45 52 41 | 54 49 4e 47 50 4f 57 45 |d(GENERA|TINGPOWE|
|00003060| 52 50 43 29 20 7c 7c 20 | 64 65 66 69 6e 65 64 28 |RPC) || |defined(|
|00003070| 47 45 4e 45 52 41 54 49 | 4e 47 36 38 4b 29 0d 09 |GENERATI|NG68K)..|
|00003080| 09 23 64 65 66 69 6e 65 | 20 55 4e 49 56 45 52 53 |.#define| UNIVERS|
|00003090| 41 4c 5f 48 45 41 44 45 | 52 53 20 32 09 2f 2a 20 |AL_HEADE|RS 2./* |
|000030a0| 76 65 72 73 69 6f 6e 20 | 32 20 2a 2f 0d 09 23 65 |version |2 */..#e|
|000030b0| 6c 73 65 0d 09 09 23 64 | 65 66 69 6e 65 20 55 4e |lse...#d|efine UN|
|000030c0| 49 56 45 52 53 41 4c 5f | 48 45 41 44 45 52 53 20 |IVERSAL_|HEADERS |
|000030d0| 31 09 2f 2a 20 76 65 72 | 73 69 6f 6e 20 31 20 2a |1./* ver|sion 1 *|
|000030e0| 2f 0d 09 23 65 6e 64 69 | 66 0d 23 65 6c 73 65 0d |/..#endi|f.#else.|
|000030f0| 09 23 64 65 66 69 6e 65 | 20 55 4e 49 56 45 52 53 |.#define| UNIVERS|
|00003100| 41 4c 5f 48 45 41 44 45 | 52 53 20 30 0d 23 65 6e |AL_HEADE|RS 0.#en|
|00003110| 64 69 66 0d 0d 2f 2a 0d | 42 61 73 65 64 20 6f 6e |dif../*.|Based on|
|00003120| 20 41 70 70 6c 65 27 73 | 20 43 6f 6e 64 69 74 69 | Apple's| Conditi|
|00003130| 6f 6e 61 6c 4d 61 63 72 | 6f 73 2e 68 2c 20 73 6f |onalMacr|os.h, so|
|00003140| 20 74 68 61 74 20 74 68 | 65 20 56 69 64 65 6f 54 | that th|e VideoT|
|00003150| 6f 6f 6c 62 6f 78 20 61 | 6e 64 20 79 6f 75 72 20 |oolbox a|nd your |
|00003160| 73 6f 75 72 63 65 73 20 | 0d 63 61 6e 20 75 73 65 |sources |.can use|
|00003170| 20 74 68 65 73 65 20 6e | 65 77 20 6d 61 63 72 6f | these n|ew macro|
|00003180| 73 20 77 69 74 68 6f 75 | 74 20 77 6f 72 72 79 69 |s withou|t worryi|
|00003190| 6e 67 20 61 62 6f 75 74 | 20 77 68 65 74 68 65 72 |ng about| whether|
|000031a0| 20 79 6f 75 27 76 65 20 | 61 63 74 75 61 6c 6c 79 | you've |actually|
|000031b0| 20 67 6f 74 20 74 68 65 | 20 0d 6e 65 77 20 68 65 | got the| .new he|
|000031c0| 61 64 65 72 73 20 28 4a | 75 6e 65 20 27 39 35 29 |aders (J|une '95)|
|000031d0| 20 69 6e 20 77 68 69 63 | 68 20 74 68 65 79 20 61 | in whic|h they a|
|000031e0| 72 65 20 66 69 72 73 74 | 20 69 6e 74 72 6f 64 75 |re first| introdu|
|000031f0| 63 65 64 2e 20 54 68 69 | 73 20 73 65 63 74 69 6f |ced. Thi|s sectio|
|00003200| 6e 20 68 61 73 20 6e 6f | 20 65 66 66 65 63 74 20 |n has no| effect |
|00003210| 69 66 0d 47 45 4e 45 52 | 41 54 49 4e 47 50 4f 57 |if.GENER|ATINGPOW|
|00003220| 45 52 50 43 20 65 74 63 | 2e 20 61 72 65 20 61 6c |ERPC etc|. are al|
|00003230| 72 65 61 64 79 20 64 65 | 66 69 6e 65 64 2e 20 54 |ready de|fined. T|
|00003240| 68 65 73 65 20 6d 61 63 | 72 6f 73 20 73 75 70 70 |hese mac|ros supp|
|00003250| 6f 72 74 20 65 61 72 6c | 79 20 76 65 72 73 69 6f |ort earl|y versio|
|00003260| 6e 73 20 6f 66 0d 54 48 | 49 4e 4b 20 43 2c 20 77 |ns of.TH|INK C, w|
|00003270| 68 69 63 68 20 41 70 70 | 6c 65 27 73 20 6e 65 77 |hich App|le's new|
|00003280| 20 68 65 61 64 65 72 73 | 20 64 6f 6e 27 74 20 73 | headers| don't s|
|00003290| 75 70 70 6f 72 74 2e 0d | 2a 2f 0d 23 69 66 20 21 |upport..|*/.#if !|
|000032a0| 64 65 66 69 6e 65 64 28 | 47 45 4e 45 52 41 54 49 |defined(|GENERATI|
|000032b0| 4e 47 50 4f 57 45 52 50 | 43 29 20 7c 7c 20 21 64 |NGPOWERP|C) || !d|
|000032c0| 65 66 69 6e 65 64 28 47 | 45 4e 45 52 41 54 49 4e |efined(G|ENERATIN|
|000032d0| 47 36 38 4b 29 0d 09 23 | 75 6e 64 65 66 20 47 45 |G68K)..#|undef GE|
|000032e0| 4e 45 52 41 54 49 4e 47 | 50 4f 57 45 52 50 43 0d |NERATING|POWERPC.|
|000032f0| 09 23 75 6e 64 65 66 20 | 47 45 4e 45 52 41 54 49 |.#undef |GENERATI|
|00003300| 4e 47 36 38 4b 0d 09 23 | 69 66 20 64 65 66 69 6e |NG68K..#|if defin|
|00003310| 65 64 28 70 6f 77 65 72 | 63 29 20 7c 7c 20 64 65 |ed(power|c) || de|
|00003320| 66 69 6e 65 64 28 5f 5f | 70 6f 77 65 72 63 29 0d |fined(__|powerc).|
|00003330| 09 09 23 64 65 66 69 6e | 65 20 47 45 4e 45 52 41 |..#defin|e GENERA|
|00003340| 54 49 4e 47 50 4f 57 45 | 52 50 43 20 31 0d 09 09 |TINGPOWE|RPC 1...|
|00003350| 23 64 65 66 69 6e 65 20 | 47 45 4e 45 52 41 54 49 |#define |GENERATI|
|00003360| 4e 47 36 38 4b 20 30 0d | 09 23 65 6c 73 65 0d 09 |NG68K 0.|.#else..|
|00003370| 09 23 64 65 66 69 6e 65 | 20 47 45 4e 45 52 41 54 |.#define| GENERAT|
|00003380| 49 4e 47 50 4f 57 45 52 | 50 43 20 30 0d 09 09 23 |INGPOWER|PC 0...#|
|00003390| 64 65 66 69 6e 65 20 47 | 45 4e 45 52 41 54 49 4e |define G|ENERATIN|
|000033a0| 47 36 38 4b 20 31 0d 09 | 23 65 6e 64 69 66 0d 23 |G68K 1..|#endif.#|
|000033b0| 65 6e 64 69 66 0d 23 69 | 66 20 47 45 4e 45 52 41 |endif.#i|f GENERA|
|000033c0| 54 49 4e 47 36 38 4b 20 | 26 26 20 21 64 65 66 69 |TING68K |&& !defi|
|000033d0| 6e 65 64 28 47 45 4e 45 | 52 41 54 49 4e 47 36 38 |ned(GENE|RATING68|
|000033e0| 38 38 31 29 0d 09 23 69 | 66 20 64 65 66 69 6e 65 |881)..#i|f define|
|000033f0| 64 28 61 70 70 6c 65 63 | 29 20 7c 7c 20 64 65 66 |d(applec|) || def|
|00003400| 69 6e 65 64 28 5f 5f 53 | 43 5f 5f 29 0d 09 09 23 |ined(__S|C__)...#|
|00003410| 69 66 64 65 66 20 6d 63 | 36 38 38 38 31 0d 09 09 |ifdef mc|68881...|
|00003420| 09 23 64 65 66 69 6e 65 | 20 47 45 4e 45 52 41 54 |.#define| GENERAT|
|00003430| 49 4e 47 36 38 38 38 31 | 20 31 0d 09 09 23 65 6e |ING68881| 1...#en|
|00003440| 64 69 66 0d 09 23 65 6c | 73 65 0d 09 09 23 69 66 |dif..#el|se...#if|
|00003450| 20 54 48 49 4e 4b 5f 43 | 20 26 26 20 54 48 49 4e | THINK_C| && THIN|
|00003460| 4b 5f 43 3d 3d 31 09 09 | 2f 2a 20 54 48 49 4e 4b |K_C==1..|/* THINK|
|00003470| 20 43 20 34 20 2a 2f 0d | 09 09 09 23 64 65 66 69 | C 4 */.|...#defi|
|00003480| 6e 65 20 47 45 4e 45 52 | 41 54 49 4e 47 36 38 38 |ne GENER|ATING688|
|00003490| 38 31 20 5f 4d 43 36 38 | 38 38 31 5f 0d 09 09 23 |81 _MC68|881_...#|
|000034a0| 65 6e 64 69 66 0d 09 09 | 23 69 66 20 53 59 4d 41 |endif...|#if SYMA|
|000034b0| 4e 54 45 43 5f 43 20 7c | 7c 20 54 48 49 4e 4b 5f |NTEC_C ||| THINK_|
|000034c0| 43 50 4c 55 53 20 7c 7c | 20 28 54 48 49 4e 4b 5f |CPLUS ||| (THINK_|
|000034d0| 43 20 26 26 20 54 48 49 | 4e 4b 5f 43 3e 31 29 09 |C && THI|NK_C>1).|
|000034e0| 2f 2a 20 54 48 49 4e 4b | 20 43 20 35 2c 36 2c 37 |/* THINK| C 5,6,7|
|000034f0| 2c 38 2c 20 43 2b 2b 2c | 20 53 59 4d 41 4e 54 45 |,8, C++,| SYMANTE|
|00003500| 43 20 43 2c 43 2b 2b 20 | 2a 2f 0d 09 09 09 23 69 |C C,C++ |*/....#i|
|00003510| 66 20 5f 5f 6f 70 74 69 | 6f 6e 28 6d 63 36 38 38 |f __opti|on(mc688|
|00003520| 38 31 29 0d 09 09 09 09 | 23 64 65 66 69 6e 65 20 |81).....|#define |
|00003530| 47 45 4e 45 52 41 54 49 | 4e 47 36 38 38 38 31 20 |GENERATI|NG68881 |
|00003540| 31 0d 09 09 09 23 65 6e | 64 69 66 0d 09 09 23 65 |1....#en|dif...#e|
|00003550| 6e 64 69 66 0d 09 09 23 | 69 66 64 65 66 20 5f 5f |ndif...#|ifdef __|
|00003560| 4d 57 45 52 4b 53 5f 5f | 0d 09 09 09 23 69 66 20 |MWERKS__|....#if |
|00003570| 5f 5f 4d 43 36 38 38 38 | 31 5f 5f 0d 09 09 09 09 |__MC6888|1__.....|
|00003580| 23 64 65 66 69 6e 65 20 | 47 45 4e 45 52 41 54 49 |#define |GENERATI|
|00003590| 4e 47 36 38 38 38 31 20 | 31 0d 09 09 09 23 65 6e |NG68881 |1....#en|
|000035a0| 64 69 66 0d 09 09 23 65 | 6e 64 69 66 0d 09 23 65 |dif...#e|ndif..#e|
|000035b0| 6e 64 69 66 0d 23 65 6e | 64 69 66 0d 23 69 66 6e |ndif.#en|dif.#ifn|
|000035c0| 64 65 66 20 47 45 4e 45 | 52 41 54 49 4e 47 36 38 |def GENE|RATING68|
|000035d0| 38 38 31 0d 09 23 64 65 | 66 69 6e 65 20 47 45 4e |881..#de|fine GEN|
|000035e0| 45 52 41 54 49 4e 47 36 | 38 38 38 31 20 30 0d 23 |ERATING6|8881 0.#|
|000035f0| 65 6e 64 69 66 0d 0d 2f | 2a 20 41 70 70 6c 65 27 |endif../|* Apple'|
|00003600| 73 20 68 65 61 64 65 72 | 73 20 64 6f 6e 27 74 20 |s header|s don't |
|00003610| 64 65 66 69 6e 65 20 47 | 45 4e 45 52 41 54 49 4e |define G|ENERATIN|
|00003620| 47 36 38 30 32 30 2c 20 | 62 75 74 20 49 64 65 6e |G68020, |but Iden|
|00003630| 74 69 66 79 2e 63 20 61 | 6e 64 20 52 65 71 75 69 |tify.c a|nd Requi|
|00003640| 72 65 2e 63 20 6e 65 65 | 64 20 69 74 2e 20 2a 2f |re.c nee|d it. */|
|00003650| 0d 23 69 66 20 47 45 4e | 45 52 41 54 49 4e 47 36 |.#if GEN|ERATING6|
|00003660| 38 4b 20 26 26 20 21 64 | 65 66 69 6e 65 64 28 47 |8K && !d|efined(G|
|00003670| 45 4e 45 52 41 54 49 4e | 47 36 38 30 32 30 29 0d |ENERATIN|G68020).|
|00003680| 09 23 69 66 20 64 65 66 | 69 6e 65 64 28 61 70 70 |.#if def|ined(app|
|00003690| 6c 65 63 29 20 7c 7c 20 | 64 65 66 69 6e 65 64 28 |lec) || |defined(|
|000036a0| 5f 5f 53 43 5f 5f 29 0d | 09 09 23 69 66 64 65 66 |__SC__).|..#ifdef|
|000036b0| 20 6d 63 36 38 30 32 30 | 0d 09 09 09 23 64 65 66 | mc68020|....#def|
|000036c0| 69 6e 65 20 47 45 4e 45 | 52 41 54 49 4e 47 36 38 |ine GENE|RATING68|
|000036d0| 30 32 30 20 31 0d 09 09 | 23 65 6e 64 69 66 0d 09 |020 1...|#endif..|
|000036e0| 23 65 6c 73 65 0d 09 09 | 23 69 66 20 54 48 49 4e |#else...|#if THIN|
|000036f0| 4b 5f 43 20 26 26 20 54 | 48 49 4e 4b 5f 43 3d 3d |K_C && T|HINK_C==|
|00003700| 31 09 09 09 2f 2a 20 54 | 48 49 4e 4b 20 43 20 34 |1.../* T|HINK C 4|
|00003710| 20 2a 2f 0d 09 09 09 23 | 64 65 66 69 6e 65 20 47 | */....#|define G|
|00003720| 45 4e 45 52 41 54 49 4e | 47 36 38 30 32 30 20 5f |ENERATIN|G68020 _|
|00003730| 4d 43 36 38 30 32 30 5f | 0d 09 09 23 65 6e 64 69 |MC68020_|...#endi|
|00003740| 66 0d 09 09 23 69 66 20 | 53 59 4d 41 4e 54 45 43 |f...#if |SYMANTEC|
|00003750| 5f 43 20 7c 7c 20 54 48 | 49 4e 4b 5f 43 50 4c 55 |_C || TH|INK_CPLU|
|00003760| 53 20 7c 7c 20 28 54 48 | 49 4e 4b 5f 43 20 26 26 |S || (TH|INK_C &&|
|00003770| 20 54 48 49 4e 4b 5f 43 | 3e 31 29 09 2f 2a 20 53 | THINK_C|>1)./* S|
|00003780| 79 6d 61 6e 74 65 63 20 | 43 2c 20 54 48 49 4e 4b |ymantec |C, THINK|
|00003790| 20 43 20 35 2c 36 2c 37 | 2c 38 20 2a 2f 0d 09 09 | C 5,6,7|,8 */...|
|000037a0| 09 23 69 66 20 5f 5f 6f | 70 74 69 6f 6e 28 6d 63 |.#if __o|ption(mc|
|000037b0| 36 38 30 32 30 29 0d 09 | 09 09 09 23 64 65 66 69 |68020)..|...#defi|
|000037c0| 6e 65 20 47 45 4e 45 52 | 41 54 49 4e 47 36 38 30 |ne GENER|ATING680|
|000037d0| 32 30 20 31 0d 09 09 09 | 23 65 6e 64 69 66 0d 09 |20 1....|#endif..|
|000037e0| 09 23 65 6e 64 69 66 0d | 09 09 23 69 66 20 5f 5f |.#endif.|..#if __|
|000037f0| 4d 57 45 52 4b 53 5f 5f | 0d 09 09 09 23 69 66 20 |MWERKS__|....#if |
|00003800| 5f 5f 4d 43 36 38 30 32 | 30 5f 5f 0d 09 09 09 09 |__MC6802|0__.....|
|00003810| 23 64 65 66 69 6e 65 20 | 47 45 4e 45 52 41 54 49 |#define |GENERATI|
|00003820| 4e 47 36 38 30 32 30 20 | 31 0d 09 09 09 23 65 6e |NG68020 |1....#en|
|00003830| 64 69 66 0d 09 09 23 65 | 6e 64 69 66 0d 09 23 65 |dif...#e|ndif..#e|
|00003840| 6e 64 69 66 0d 23 65 6e | 64 69 66 0d 23 69 66 20 |ndif.#en|dif.#if |
|00003850| 21 64 65 66 69 6e 65 64 | 28 47 45 4e 45 52 41 54 |!defined|(GENERAT|
|00003860| 49 4e 47 36 38 30 32 30 | 29 0d 09 23 64 65 66 69 |ING68020|)..#defi|
|00003870| 6e 65 20 47 45 4e 45 52 | 41 54 49 4e 47 36 38 30 |ne GENER|ATING680|
|00003880| 32 30 20 30 0d 23 65 6e | 64 69 66 0d 0d 23 69 66 |20 0.#en|dif..#if|
|00003890| 20 21 64 65 66 69 6e 65 | 64 28 4d 41 54 4c 41 42 | !define|d(MATLAB|
|000038a0| 29 0d 09 23 64 65 66 69 | 6e 65 20 4d 41 54 4c 41 |)..#defi|ne MATLA|
|000038b0| 42 20 30 0d 23 65 6e 64 | 69 66 0d 23 69 66 20 4d |B 0.#end|if.#if M|
|000038c0| 41 54 4c 41 42 0d 09 2f | 2a 0d 09 54 68 69 73 20 |ATLAB../|*..This |
|000038d0| 6d 75 73 74 20 63 6f 6d | 65 20 61 66 74 65 72 20 |must com|e after |
|000038e0| 73 74 64 6c 69 62 2e 68 | 2c 20 73 74 64 69 6f 2e |stdlib.h|, stdio.|
|000038f0| 68 2c 20 61 6e 64 20 51 | 75 69 63 6b 44 72 61 77 |h, and Q|uickDraw|
|00003900| 2e 68 20 61 6e 64 20 62 | 65 66 6f 72 65 20 65 76 |.h and b|efore ev|
|00003910| 65 72 79 74 68 69 6e 67 | 0d 09 65 6c 73 65 2e 20 |erything|..else. |
|00003920| 49 66 20 4d 41 54 4c 41 | 42 20 69 73 20 74 72 75 |If MATLA|B is tru|
|00003930| 65 20 74 68 65 6e 20 77 | 65 20 69 6e 63 6c 75 64 |e then w|e includ|
|00003940| 65 20 74 68 65 20 68 65 | 61 64 65 72 20 66 69 6c |e the he|ader fil|
|00003950| 65 20 63 6d 65 78 2e 68 | 2e 20 20 4f 74 68 65 72 |e cmex.h|. Other|
|00003960| 77 69 73 65 20 77 65 0d | 09 64 65 66 69 6e 65 20 |wise we.|.define |
|00003970| 74 68 65 20 64 61 74 61 | 20 74 79 70 65 73 20 74 |the data| types t|
|00003980| 68 61 74 20 61 72 65 20 | 6e 6f 72 6d 61 6c 6c 79 |hat are |normally|
|00003990| 20 70 72 6f 76 69 64 65 | 64 20 62 79 20 74 68 61 | provide|d by tha|
|000039a0| 74 20 68 65 61 64 65 72 | 2c 20 73 6f 20 74 68 61 |t header|, so tha|
|000039b0| 74 20 63 6f 64 65 0d 09 | 74 68 61 74 20 75 73 65 |t code..|that use|
|000039c0| 73 20 74 68 65 73 65 20 | 74 79 70 65 73 20 6d 61 |s these |types ma|
|000039d0| 79 20 62 65 20 63 6f 6d | 70 69 6c 65 64 20 66 6f |y be com|piled fo|
|000039e0| 72 20 75 73 65 20 69 6e | 20 61 70 70 6c 69 63 61 |r use in| applica|
|000039f0| 74 69 6f 6e 73 2e 20 20 | 49 74 20 6d 75 73 74 20 |tions. |It must |
|00003a00| 63 6f 6d 65 0d 09 62 65 | 66 6f 72 65 20 77 65 20 |come..be|fore we |
|00003a10| 74 65 73 74 20 66 6f 72 | 20 76 65 72 73 69 6f 6e |test for| version|
|00003a20| 20 33 20 6f 72 20 34 2e | 20 20 54 68 65 20 76 65 | 3 or 4.| The ve|
|00003a30| 72 73 69 6f 6e 20 33 20 | 63 6d 65 78 2e 68 20 64 |rsion 3 |cmex.h d|
|00003a40| 6f 65 73 20 6e 6f 74 20 | 64 65 66 69 6e 65 20 74 |oes not |define t|
|00003a50| 68 65 0d 09 73 79 6d 62 | 6f 6c 20 6d 65 78 5f 68 |he..symb|ol mex_h|
|00003a60| 3b 20 76 65 72 73 69 6f | 6e 20 34 20 64 6f 65 73 |; versio|n 4 does|
|00003a70| 2e 20 20 54 68 69 73 20 | 69 73 20 77 68 61 74 20 |. This |is what |
|00003a80| 77 65 20 75 73 65 20 74 | 6f 20 66 69 67 75 72 65 |we use t|o figure|
|00003a90| 20 6f 75 74 20 77 68 69 | 63 68 0d 09 76 65 72 73 | out whi|ch..vers|
|00003aa0| 69 6f 6e 20 77 65 20 61 | 72 65 20 63 6f 6d 70 69 |ion we a|re compi|
|00003ab0| 6c 69 6e 67 20 66 6f 72 | 2e 20 20 53 6f 75 6e 64 |ling for|. Sound|
|00003ac0| 20 63 6f 6d 70 6c 69 63 | 61 74 65 64 3f 20 20 53 | complic|ated? S|
|00003ad0| 69 67 68 21 20 64 68 62 | 0d 09 2a 2f 0d 09 0d 09 |igh! dhb|..*/....|
|00003ae0| 23 69 6e 63 6c 75 64 65 | 20 22 63 6d 65 78 2e 68 |#include| "cmex.h|
|00003af0| 22 0d 09 2f 2a 20 54 65 | 73 74 20 66 6f 72 20 4d |"../* Te|st for M|
|00003b00| 41 54 4c 41 42 20 34 20 | 6f 72 20 4d 41 54 4c 41 |ATLAB 4 |or MATLA|
|00003b10| 42 20 33 2c 20 61 6e 64 | 20 73 65 74 20 73 79 6d |B 3, and| set sym|
|00003b20| 62 6f 6c 20 61 70 70 72 | 6f 70 72 69 61 74 65 6c |bol appr|opriatel|
|00003b30| 79 2e 20 2a 2f 0d 09 23 | 75 6e 64 65 66 20 4d 41 |y. */..#|undef MA|
|00003b40| 54 4c 41 42 0d 09 23 69 | 66 64 65 66 20 6d 65 78 |TLAB..#i|fdef mex|
|00003b50| 5f 68 0d 09 09 23 64 65 | 66 69 6e 65 20 4d 41 54 |_h...#de|fine MAT|
|00003b60| 4c 41 42 20 34 0d 09 23 | 65 6c 73 65 0d 09 09 23 |LAB 4..#|else...#|
|00003b70| 64 65 66 69 6e 65 20 4d | 41 54 4c 41 42 20 33 0d |define M|ATLAB 3.|
|00003b80| 09 23 65 6e 64 69 66 0d | 09 23 69 66 20 21 4d 41 |.#endif.|.#if !MA|
|00003b90| 43 5f 43 0d 09 09 23 65 | 72 72 6f 72 20 22 4d 41 |C_C...#e|rror "MA|
|00003ba0| 54 4c 41 42 20 72 65 71 | 75 69 72 65 73 20 74 68 |TLAB req|uires th|
|00003bb0| 65 20 4d 61 63 69 6e 74 | 6f 73 68 20 65 78 74 65 |e Macint|osh exte|
|00003bc0| 6e 73 69 6f 6e 73 20 74 | 6f 20 43 2e 22 0d 09 23 |nsions t|o C."..#|
|00003bd0| 65 6e 64 69 66 0d 0d 20 | 20 20 20 2f 2a 0d 09 55 |endif.. | /*..U|
|00003be0| 6e 64 65 66 69 6e 65 20 | 74 68 65 20 6d 61 63 72 |ndefine |the macr|
|00003bf0| 6f 73 20 74 68 61 74 20 | 6f 76 65 72 72 69 64 65 |os that |override|
|00003c00| 20 6d 65 6d 6f 72 79 20 | 61 6c 6c 6f 63 61 74 69 | memory |allocati|
|00003c10| 6f 6e 2e 20 20 4d 41 54 | 4c 41 42 27 73 20 69 6d |on. MAT|LAB's im|
|00003c20| 70 6c 65 6d 65 6e 74 61 | 74 69 6f 6e 0d 20 20 20 |plementa|tion. |
|00003c30| 20 64 6f 65 73 6e 27 74 | 20 77 6f 72 6b 20 69 66 | doesn't| work if|
|00003c40| 20 79 6f 75 20 75 73 65 | 20 72 65 61 6c 6c 6f 63 | you use| realloc|
|00003c50| 2e 0d 09 2a 2f 0d 09 23 | 75 6e 64 65 66 20 6d 61 |...*/..#|undef ma|
|00003c60| 6c 6c 6f 63 0d 09 23 75 | 6e 64 65 66 20 63 61 6c |lloc..#u|ndef cal|
|00003c70| 6c 6f 63 0d 09 23 75 6e | 64 65 66 20 66 72 65 65 |loc..#un|def free|
|00003c80| 0d 09 0d 09 2f 2a 20 44 | 65 66 69 6e 65 20 64 61 |..../* D|efine da|
|00003c90| 74 61 20 74 79 70 65 73 | 20 66 6f 72 20 70 72 69 |ta types| for pri|
|00003ca0| 6e 74 66 2c 20 73 63 61 | 6e 66 2e 20 2a 2f 0d 09 |ntf, sca|nf. */..|
|00003cb0| 23 69 66 20 4d 41 54 4c | 41 42 3d 3d 34 09 09 09 |#if MATL|AB==4...|
|00003cc0| 09 09 2f 2a 20 56 65 72 | 73 69 6f 6e 20 34 20 2a |../* Ver|sion 4 *|
|00003cd0| 2f 0d 09 09 23 69 66 20 | 47 45 4e 45 52 41 54 49 |/...#if |GENERATI|
|00003ce0| 4e 47 36 38 4b 0d 09 09 | 09 74 79 70 65 64 65 66 |NG68K...|.typedef|
|00003cf0| 20 73 68 6f 72 74 20 69 | 6e 74 20 50 52 49 4e 54 | short i|nt PRINT|
|00003d00| 46 5f 49 4e 54 3b 09 09 | 2f 2a 20 74 79 70 65 20 |F_INT;..|/* type |
|00003d10| 6f 66 20 61 72 67 75 6d | 65 6e 74 73 20 74 6f 20 |of argum|ents to |
|00003d20| 70 72 69 6e 74 66 20 65 | 74 20 61 6c 2e 20 2a 2f |printf e|t al. */|
|00003d30| 0d 09 09 09 74 79 70 65 | 64 65 66 20 6c 6f 6e 67 |....type|def long|
|00003d40| 20 64 6f 75 62 6c 65 20 | 50 52 49 4e 54 46 5f 44 | double |PRINTF_D|
|00003d50| 4f 55 42 4c 45 3b 0d 09 | 09 09 74 79 70 65 64 65 |OUBLE;..|..typede|
|00003d60| 66 09 69 6e 74 20 53 43 | 41 4e 46 5f 49 4e 54 3b |f.int SC|ANF_INT;|
|00003d70| 09 09 09 09 2f 2a 20 74 | 79 70 65 20 6f 66 20 61 |..../* t|ype of a|
|00003d80| 72 67 75 6d 65 6e 74 73 | 20 74 6f 20 73 63 61 6e |rguments| to scan|
|00003d90| 66 20 65 74 20 61 6c 2e | 20 2a 2f 0d 09 09 09 74 |f et al.| */....t|
|00003da0| 79 70 65 64 65 66 20 64 | 6f 75 62 6c 65 20 53 43 |ypedef d|ouble SC|
|00003db0| 41 4e 46 5f 44 4f 55 42 | 4c 45 3b 0d 09 09 23 65 |ANF_DOUB|LE;...#e|
|00003dc0| 6e 64 69 66 0d 09 09 23 | 69 66 20 47 45 4e 45 52 |ndif...#|if GENER|
|00003dd0| 41 54 49 4e 47 50 4f 57 | 45 52 50 43 0d 09 09 09 |ATINGPOW|ERPC....|
|00003de0| 74 79 70 65 64 65 66 20 | 69 6e 74 20 50 52 49 4e |typedef |int PRIN|
|00003df0| 54 46 5f 49 4e 54 3b 09 | 09 09 09 2f 2a 20 74 79 |TF_INT;.|.../* ty|
|00003e00| 70 65 20 6f 66 20 61 72 | 67 75 6d 65 6e 74 73 20 |pe of ar|guments |
|00003e10| 74 6f 20 70 72 69 6e 74 | 66 20 65 74 20 61 6c 2e |to print|f et al.|
|00003e20| 20 2a 2f 0d 09 09 09 74 | 79 70 65 64 65 66 20 64 | */....t|ypedef d|
|00003e30| 6f 75 62 6c 65 20 50 52 | 49 4e 54 46 5f 44 4f 55 |ouble PR|INTF_DOU|
|00003e40| 42 4c 45 3b 0d 09 09 09 | 74 79 70 65 64 65 66 20 |BLE;....|typedef |
|00003e50| 69 6e 74 20 53 43 41 4e | 46 5f 49 4e 54 3b 09 09 |int SCAN|F_INT;..|
|00003e60| 09 09 2f 2a 20 74 79 70 | 65 20 6f 66 20 61 72 67 |../* typ|e of arg|
|00003e70| 75 6d 65 6e 74 73 20 74 | 6f 20 73 63 61 6e 66 20 |uments t|o scanf |
|00003e80| 65 74 20 61 6c 2e 20 2a | 2f 0d 09 09 09 74 79 70 |et al. *|/....typ|
|00003e90| 65 64 65 66 20 64 6f 75 | 62 6c 65 20 53 43 41 4e |edef dou|ble SCAN|
|00003ea0| 46 5f 44 4f 55 42 4c 45 | 3b 0d 09 09 23 65 6e 64 |F_DOUBLE|;...#end|
|00003eb0| 69 66 0d 09 23 65 6e 64 | 69 66 0d 09 23 69 66 20 |if..#end|if..#if |
|00003ec0| 54 48 49 4e 4b 5f 43 20 | 7c 7c 20 54 48 49 4e 4b |THINK_C ||| THINK|
|00003ed0| 5f 43 50 4c 55 53 20 7c | 7c 20 53 59 4d 41 4e 54 |_CPLUS ||| SYMANT|
|00003ee0| 45 43 5f 43 09 2f 2a 20 | 44 65 63 6c 61 72 65 20 |EC_C./* |Declare |
|00003ef0| 6f 75 72 20 6f 77 6e 20 | 51 75 69 63 6b 44 72 61 |our own |QuickDra|
|00003f00| 77 20 67 6c 6f 62 61 6c | 73 2c 20 61 6c 6c 6f 63 |w global|s, alloc|
|00003f10| 61 74 65 64 20 62 79 20 | 4d 41 54 4c 41 42 4d 61 |ated by |MATLABMa|
|00003f20| 69 6e 2e 68 20 2a 2f 0d | 09 09 65 78 74 65 72 6e |in.h */.|..extern|
|00003f30| 20 54 48 49 4e 4b 5f 43 | 5f 51 44 20 6d 65 78 5f | THINK_C|_QD mex_|
|00003f40| 71 64 3b 0d 09 09 23 64 | 65 66 69 6e 65 20 71 64 |qd;...#d|efine qd|
|00003f50| 20 6d 65 78 5f 71 64 0d | 09 23 65 6c 73 65 0d 09 | mex_qd.|.#else..|
|00003f60| 09 23 64 65 66 69 6e 65 | 20 6d 65 78 5f 71 64 20 |.#define| mex_qd |
|00003f70| 71 64 0d 09 23 65 6e 64 | 69 66 0d 23 65 6c 73 65 |qd..#end|if.#else|
|00003f80| 0d 09 74 79 70 65 64 65 | 66 20 6c 6f 6e 67 20 69 |..typede|f long i|
|00003f90| 6e 74 20 49 4e 54 3b 0d | 09 23 69 66 20 53 48 4f |nt INT;.|.#if SHO|
|00003fa0| 52 54 5f 44 4f 55 42 4c | 45 5f 4f 4b 0d 09 09 74 |RT_DOUBL|E_OK...t|
|00003fb0| 79 70 65 64 65 66 20 73 | 68 6f 72 74 20 64 6f 75 |ypedef s|hort dou|
|00003fc0| 62 6c 65 20 44 4f 55 42 | 4c 45 3b 2f 2a 20 6e 6f |ble DOUB|LE;/* no|
|00003fd0| 74 20 61 6c 6c 6f 77 65 | 64 20 62 79 20 53 74 61 |t allowe|d by Sta|
|00003fe0| 6e 64 61 72 64 20 43 20 | 2a 2f 0d 09 23 65 6c 73 |ndard C |*/..#els|
|00003ff0| 65 0d 09 09 74 79 70 65 | 64 65 66 20 64 6f 75 62 |e...type|def doub|
|00004000| 6c 65 20 44 4f 55 42 4c | 45 3b 0d 09 23 65 6e 64 |le DOUBL|E;..#end|
|00004010| 69 66 0d 09 74 79 70 65 | 64 65 66 20 69 6e 74 20 |if..type|def int |
|00004020| 50 52 49 4e 54 46 5f 49 | 4e 54 3b 09 09 09 2f 2a |PRINTF_I|NT;.../*|
|00004030| 20 74 79 70 65 20 6f 66 | 20 61 72 67 75 6d 65 6e | type of| argumen|
|00004040| 74 73 20 74 6f 20 70 72 | 69 6e 74 66 20 65 74 20 |ts to pr|intf et |
|00004050| 61 6c 2e 20 2a 2f 0d 09 | 74 79 70 65 64 65 66 20 |al. */..|typedef |
|00004060| 64 6f 75 62 6c 65 20 50 | 52 49 4e 54 46 5f 44 4f |double P|RINTF_DO|
|00004070| 55 42 4c 45 3b 0d 09 74 | 79 70 65 64 65 66 20 69 |UBLE;..t|ypedef i|
|00004080| 6e 74 20 53 43 41 4e 46 | 5f 49 4e 54 3b 09 09 09 |nt SCANF|_INT;...|
|00004090| 2f 2a 20 74 79 70 65 20 | 6f 66 20 61 72 67 75 6d |/* type |of argum|
|000040a0| 65 6e 74 73 20 74 6f 20 | 73 63 61 6e 66 20 65 74 |ents to |scanf et|
|000040b0| 20 61 6c 2e 20 2a 2f 0d | 09 74 79 70 65 64 65 66 | al. */.|.typedef|
|000040c0| 20 64 6f 75 62 6c 65 20 | 53 43 41 4e 46 5f 44 4f | double |SCANF_DO|
|000040d0| 55 42 4c 45 3b 0d 09 23 | 69 66 20 53 48 4f 52 54 |UBLE;..#|if SHORT|
|000040e0| 5f 44 4f 55 42 4c 45 5f | 4f 4b 0d 09 09 23 69 66 |_DOUBLE_|OK...#if|
|000040f0| 20 50 52 41 47 4d 41 5f | 41 4c 49 47 4e 5f 53 55 | PRAGMA_|ALIGN_SU|
|00004100| 50 50 4f 52 54 45 44 20 | 7c 7c 20 5f 5f 4d 57 45 |PPORTED ||| __MWE|
|00004110| 52 4b 53 5f 5f 0d 09 09 | 09 23 70 72 61 67 6d 61 |RKS__...|.#pragma|
|00004120| 20 6f 70 74 69 6f 6e 73 | 20 61 6c 69 67 6e 3d 6e | options| align=n|
|00004130| 61 74 69 76 65 0d 09 09 | 23 65 6e 64 69 66 0d 09 |ative...|#endif..|
|00004140| 09 74 79 70 65 64 65 66 | 20 73 74 72 75 63 74 20 |.typedef| struct |
|00004150| 7b 0d 09 09 09 63 68 61 | 72 20 2a 6e 61 6d 65 3b |{....cha|r *name;|
|00004160| 0d 09 09 09 49 4e 54 20 | 74 79 70 65 3b 0d 09 09 |....INT |type;...|
|00004170| 09 49 4e 54 20 6d 3b 0d | 09 09 09 49 4e 54 20 6e |.INT m;.|...INT n|
|00004180| 3b 0d 09 09 09 44 4f 55 | 42 4c 45 20 2a 70 72 3b |;....DOU|BLE *pr;|
|00004190| 0d 09 09 09 44 4f 55 42 | 4c 45 20 2a 70 69 3b 0d |....DOUB|LE *pi;.|
|000041a0| 09 09 7d 20 4d 61 74 72 | 69 78 3b 0d 09 09 23 69 |..} Matr|ix;...#i|
|000041b0| 66 20 50 52 41 47 4d 41 | 5f 41 4c 49 47 4e 5f 53 |f PRAGMA|_ALIGN_S|
|000041c0| 55 50 50 4f 52 54 45 44 | 20 7c 7c 20 5f 5f 4d 57 |UPPORTED| || __MW|
|000041d0| 45 52 4b 53 5f 5f 0d 09 | 09 09 23 70 72 61 67 6d |ERKS__..|..#pragm|
|000041e0| 61 20 6f 70 74 69 6f 6e | 73 20 61 6c 69 67 6e 3d |a option|s align=|
|000041f0| 72 65 73 65 74 0d 09 09 | 23 65 6e 64 69 66 0d 09 |reset...|#endif..|
|00004200| 23 65 6e 64 69 66 0d 23 | 65 6e 64 69 66 0d 0d 2f |#endif.#|endif../|
|00004210| 2a 20 20 53 74 61 6e 64 | 61 72 64 20 43 20 68 65 |* Stand|ard C he|
|00004220| 61 64 65 72 73 20 2a 2f | 0d 23 69 66 20 4d 41 54 |aders */|.#if MAT|
|00004230| 4c 41 42 0d 09 2f 2a 20 | 54 68 65 20 3c 61 73 73 |LAB../* |The <ass|
|00004240| 65 72 74 2e 68 3e 20 6d | 61 63 72 6f 20 72 65 71 |ert.h> m|acro req|
|00004250| 75 69 72 65 73 20 6d 6f | 64 69 66 69 63 61 74 69 |uires mo|dificati|
|00004260| 6f 6e 20 74 6f 20 77 6f | 72 6b 20 69 6e 20 61 20 |on to wo|rk in a |
|00004270| 4d 41 54 4c 41 42 20 73 | 68 61 72 65 64 20 6c 69 |MATLAB s|hared li|
|00004280| 62 72 61 72 79 2e 20 2a | 2f 0d 09 23 64 65 66 69 |brary. *|/..#defi|
|00004290| 6e 65 20 4e 44 45 42 55 | 47 09 09 2f 2a 20 64 69 |ne NDEBU|G../* di|
|000042a0| 73 61 62 6c 65 20 74 68 | 65 20 73 74 61 6e 64 61 |sable th|e standa|
|000042b0| 72 64 20 61 73 73 65 72 | 74 2e 68 20 6d 61 63 72 |rd asser|t.h macr|
|000042c0| 6f 20 2a 2f 0d 09 23 75 | 6e 64 65 66 20 61 73 73 |o */..#u|ndef ass|
|000042d0| 65 72 74 0d 09 23 64 65 | 66 69 6e 65 20 61 73 73 |ert..#de|fine ass|
|000042e0| 65 72 74 28 78 29 09 69 | 66 28 21 28 78 29 29 7b |ert(x).i|f(!(x)){|
|000042f0| 5c 0d 09 09 50 72 69 6e | 74 66 45 78 69 74 28 22 |\...Prin|tfExit("|
|00004300| 41 73 73 65 72 74 69 6f | 6e 20 28 22 20 23 78 20 |Assertio|n (" #x |
|00004310| 22 29 20 66 61 69 6c 65 | 64 20 61 74 20 25 73 3a |") faile|d at %s:|
|00004320| 25 64 5c 6e 22 2c 5f 5f | 46 49 4c 45 5f 5f 2c 5f |%d\n",__|FILE__,_|
|00004330| 5f 4c 49 4e 45 5f 5f 29 | 3b 5c 0d 09 7d 0d 23 65 |_LINE__)|;\..}.#e|
|00004340| 6c 73 65 0d 09 23 69 6e | 63 6c 75 64 65 20 3c 61 |lse..#in|clude <a|
|00004350| 73 73 65 72 74 2e 68 3e | 0d 23 65 6e 64 69 66 0d |ssert.h>|.#endif.|
|00004360| 23 69 6e 63 6c 75 64 65 | 20 3c 63 74 79 70 65 2e |#include| <ctype.|
|00004370| 68 3e 0d 23 69 6e 63 6c | 75 64 65 20 3c 66 6c 6f |h>.#incl|ude <flo|
|00004380| 61 74 2e 68 3e 0d 23 69 | 6e 63 6c 75 64 65 20 3c |at.h>.#i|nclude <|
|00004390| 6c 69 6d 69 74 73 2e 68 | 3e 0d 23 69 6e 63 6c 75 |limits.h|>.#inclu|
|000043a0| 64 65 20 3c 73 74 64 6c | 69 62 2e 68 3e 0d 23 69 |de <stdl|ib.h>.#i|
|000043b0| 6e 63 6c 75 64 65 20 3c | 73 74 72 69 6e 67 2e 68 |nclude <|string.h|
|000043c0| 3e 0d 23 69 6e 63 6c 75 | 64 65 20 3c 74 69 6d 65 |>.#inclu|de <time|
|000043d0| 2e 68 3e 0d 23 69 66 20 | 21 64 65 66 69 6e 65 64 |.h>.#if |!defined|
|000043e0| 28 5f 5f 4d 41 54 48 5f | 5f 29 20 26 26 20 28 55 |(__MATH_|_) && (U|
|000043f0| 4e 49 56 45 52 53 41 4c | 5f 48 45 41 44 45 52 53 |NIVERSAL|_HEADERS|
|00004400| 3e 3d 32 29 20 26 26 20 | 21 54 48 49 4e 4b 5f 43 |>=2) && |!THINK_C|
|00004410| 0d 09 23 69 6e 63 6c 75 | 64 65 20 3c 66 70 2e 68 |..#inclu|de <fp.h|
|00004420| 3e 0d 23 65 6c 73 65 0d | 09 23 69 66 20 47 45 4e |>.#else.|.#if GEN|
|00004430| 45 52 41 54 49 4e 47 50 | 4f 57 45 52 50 43 20 7c |ERATINGP|OWERPC ||
|00004440| 7c 20 47 45 4e 45 52 41 | 54 49 4e 47 36 38 38 38 || GENERA|TING6888|
|00004450| 31 0d 09 09 2f 2a 20 61 | 73 20 61 64 76 69 73 65 |1.../* a|s advise|
|00004460| 64 20 62 79 20 6d 61 74 | 68 2e 68 2c 20 77 65 20 |d by mat|h.h, we |
|00004470| 64 6f 6e 27 74 20 65 6e | 61 62 6c 65 20 74 68 65 |don't en|able the|
|00004480| 73 65 20 69 66 20 75 73 | 69 6e 67 20 38 2d 62 79 |se if us|ing 8-by|
|00004490| 74 65 20 64 6f 75 62 6c | 65 73 20 6f 6e 20 36 38 |te doubl|es on 68|
|000044a0| 6b 20 2a 2f 0d 09 09 23 | 75 6e 64 65 66 20 5f 4e |k */...#|undef _N|
|000044b0| 4f 45 52 52 4f 52 43 48 | 45 43 4b 5f 0d 09 09 23 |OERRORCH|ECK_...#|
|000044c0| 75 6e 64 65 66 20 5f 49 | 4e 4c 49 4e 45 5f 46 50 |undef _I|NLINE_FP|
|000044d0| 55 5f 43 41 4c 4c 53 5f | 0d 09 09 23 64 65 66 69 |U_CALLS_|...#defi|
|000044e0| 6e 65 20 5f 4e 4f 45 52 | 52 4f 52 43 48 45 43 4b |ne _NOER|RORCHECK|
|000044f0| 5f 20 31 09 09 2f 2a 20 | 65 6e 63 6f 75 72 61 67 |_ 1../* |encourag|
|00004500| 65 20 75 73 65 20 6f 66 | 20 38 38 38 31 20 69 6e |e use of| 8881 in|
|00004510| 74 72 69 6e 73 69 63 20 | 66 75 6e 63 74 69 6f 6e |trinsic |function|
|00004520| 73 20 2a 2f 0d 09 09 23 | 64 65 66 69 6e 65 20 5f |s */...#|define _|
|00004530| 49 4e 4c 49 4e 45 5f 46 | 50 55 5f 43 41 4c 4c 53 |INLINE_F|PU_CALLS|
|00004540| 5f 20 31 09 2f 2a 20 65 | 6e 63 6f 75 72 61 67 65 |_ 1./* e|ncourage|
|00004550| 20 75 73 65 20 6f 66 20 | 38 38 38 31 20 69 6e 74 | use of |8881 int|
|00004560| 72 69 6e 73 69 63 20 66 | 75 6e 63 74 69 6f 6e 73 |rinsic f|unctions|
|00004570| 20 2a 2f 0d 09 23 65 6e | 64 69 66 0d 09 23 69 6e | */..#en|dif..#in|
|00004580| 63 6c 75 64 65 20 3c 6d | 61 74 68 2e 68 3e 0d 09 |clude <m|ath.h>..|
|00004590| 23 69 66 20 21 64 65 66 | 69 6e 65 64 28 5f 5f 46 |#if !def|ined(__F|
|000045a0| 50 5f 5f 29 09 2f 2a 20 | 6d 61 6b 65 20 73 75 72 |P__)./* |make sur|
|000045b0| 65 20 74 68 61 74 20 6d | 61 74 68 2e 68 20 68 61 |e that m|ath.h ha|
|000045c0| 73 6e 27 74 20 69 6e 63 | 6c 75 64 65 64 20 66 70 |sn't inc|luded fp|
|000045d0| 2e 68 20 2a 2f 0d 09 09 | 23 75 6e 64 65 66 20 72 |.h */...|#undef r|
|000045e0| 6f 75 6e 64 0d 09 09 23 | 64 65 66 69 6e 65 20 72 |ound...#|define r|
|000045f0| 6f 75 6e 64 28 78 29 20 | 66 6c 6f 6f 72 28 30 2e |ound(x) |floor(0.|
|00004600| 35 2b 28 78 29 29 09 2f | 2a 20 75 73 65 64 20 62 |5+(x))./|* used b|
|00004610| 79 20 6d 61 6e 79 20 56 | 69 64 65 6f 54 6f 6f 6c |y many V|ideoTool|
|00004620| 62 6f 78 20 72 6f 75 74 | 69 6e 65 73 20 2a 2f 0d |box rout|ines */.|
|00004630| 09 23 65 6e 64 69 66 0d | 23 65 6e 64 69 66 0d 0d |.#endif.|#endif..|
|00004640| 2f 2a 20 20 4d 61 63 69 | 6e 74 6f 73 68 20 68 65 |/* Maci|ntosh he|
|00004650| 61 64 65 72 73 20 2a 2f | 0d 23 69 66 20 4d 41 43 |aders */|.#if MAC|
|00004660| 5f 43 0d 09 23 69 66 20 | 54 48 49 4e 4b 5f 43 20 |_C..#if |THINK_C |
|00004670| 7c 7c 20 54 48 49 4e 4b | 5f 43 50 4c 55 53 20 7c ||| THINK|_CPLUS ||
|00004680| 7c 20 53 59 4d 41 4e 54 | 45 43 5f 43 0d 09 09 23 || SYMANT|EC_C...#|
|00004690| 69 6e 63 6c 75 64 65 20 | 3c 63 6f 6e 73 6f 6c 65 |include |<console|
|000046a0| 2e 68 3e 0d 09 23 65 6e | 64 69 66 0d 09 23 69 6e |.h>..#en|dif..#in|
|000046b0| 63 6c 75 64 65 20 3c 44 | 65 76 69 63 65 73 2e 68 |clude <D|evices.h|
|000046c0| 3e 0d 09 23 69 6e 63 6c | 75 64 65 20 3c 45 72 72 |>..#incl|ude <Err|
|000046d0| 6f 72 73 2e 68 3e 0d 09 | 23 69 6e 63 6c 75 64 65 |ors.h>..|#include|
|000046e0| 20 3c 45 76 65 6e 74 73 | 2e 68 3e 0d 09 23 69 6e | <Events|.h>..#in|
|000046f0| 63 6c 75 64 65 20 3c 46 | 69 78 4d 61 74 68 2e 68 |clude <F|ixMath.h|
|00004700| 3e 0d 09 23 69 6e 63 6c | 75 64 65 20 3c 46 6f 6e |>..#incl|ude <Fon|
|00004710| 74 73 2e 68 3e 0d 09 23 | 69 66 20 55 4e 49 56 45 |ts.h>..#|if UNIVE|
|00004720| 52 53 41 4c 5f 48 45 41 | 44 45 52 53 3e 32 0d 09 |RSAL_HEA|DERS>2..|
|00004730| 09 23 69 6e 63 6c 75 64 | 65 20 3c 47 65 73 74 61 |.#includ|e <Gesta|
|00004740| 6c 74 2e 68 3e 09 2f 2a | 20 41 70 70 6c 65 20 61 |lt.h>./*| Apple a|
|00004750| 62 62 72 65 76 69 61 74 | 65 64 20 74 68 65 20 66 |bbreviat|ed the f|
|00004760| 69 6c 65 6e 61 6d 65 20 | 2a 2f 0d 09 23 65 6c 73 |ilename |*/..#els|
|00004770| 65 0d 09 09 23 69 6e 63 | 6c 75 64 65 20 3c 47 65 |e...#inc|lude <Ge|
|00004780| 73 74 61 6c 74 45 71 75 | 2e 68 3e 0d 09 23 65 6e |staltEqu|.h>..#en|
|00004790| 64 69 66 0d 09 23 69 6e | 63 6c 75 64 65 20 3c 4d |dif..#in|clude <M|
|000047a0| 65 6d 6f 72 79 2e 68 3e | 0d 09 23 69 6e 63 6c 75 |emory.h>|..#inclu|
|000047b0| 64 65 20 3c 4d 65 6e 75 | 73 2e 68 3e 0d 09 23 69 |de <Menu|s.h>..#i|
|000047c0| 6e 63 6c 75 64 65 20 3c | 4f 53 45 76 65 6e 74 73 |nclude <|OSEvents|
|000047d0| 2e 68 3e 0d 09 23 69 6e | 63 6c 75 64 65 20 3c 4f |.h>..#in|clude <O|
|000047e0| 53 55 74 69 6c 73 2e 68 | 3e 09 2f 2a 20 20 72 65 |SUtils.h|>./* re|
|000047f0| 71 75 69 72 65 64 20 2a | 2f 0d 09 23 69 6e 63 6c |quired *|/..#incl|
|00004800| 75 64 65 20 3c 50 61 63 | 6b 61 67 65 73 2e 68 3e |ude <Pac|kages.h>|
|00004810| 0d 09 23 69 6e 63 6c 75 | 64 65 20 3c 50 61 6c 65 |..#inclu|de <Pale|
|00004820| 74 74 65 73 2e 68 3e 0d | 09 23 69 66 20 28 54 48 |ttes.h>.|.#if (TH|
|00004830| 49 4e 4b 5f 43 20 7c 7c | 20 54 48 49 4e 4b 5f 43 |INK_C ||| THINK_C|
|00004840| 50 4c 55 53 20 7c 7c 20 | 53 59 4d 41 4e 54 45 43 |PLUS || |SYMANTEC|
|00004850| 5f 43 29 0d 09 09 23 69 | 6e 63 6c 75 64 65 20 3c |_C)...#i|nclude <|
|00004860| 70 72 6f 66 69 6c 65 2e | 68 3e 2f 2a 20 6f 6e 6c |profile.|h>/* onl|
|00004870| 79 20 6e 65 65 64 65 64 | 20 69 66 20 79 6f 75 20 |y needed| if you |
|00004880| 77 61 6e 74 20 74 69 6d | 69 6e 67 20 69 6e 66 6f |want tim|ing info|
|00004890| 20 2a 2f 0d 09 23 65 6e | 64 69 66 0d 09 23 69 6e | */..#en|dif..#in|
|000048a0| 63 6c 75 64 65 20 3c 51 | 44 4f 66 66 73 63 72 65 |clude <Q|DOffscre|
|000048b0| 65 6e 2e 68 3e 0d 09 23 | 69 6e 63 6c 75 64 65 20 |en.h>..#|include |
|000048c0| 3c 52 65 73 6f 75 72 63 | 65 73 2e 68 3e 0d 09 23 |<Resourc|es.h>..#|
|000048d0| 69 6e 63 6c 75 64 65 20 | 3c 52 65 74 72 61 63 65 |include |<Retrace|
|000048e0| 2e 68 3e 09 2f 2a 20 20 | 72 65 71 75 69 72 65 64 |.h>./* |required|
|000048f0| 20 2a 2f 0d 09 23 69 66 | 20 5f 5f 4d 57 45 52 4b | */..#if| __MWERK|
|00004900| 53 5f 5f 0d 09 09 23 69 | 6e 63 6c 75 64 65 20 3c |S__...#i|nclude <|
|00004910| 53 49 4f 55 58 2e 68 3e | 0d 09 23 65 6e 64 69 66 |SIOUX.h>|..#endif|
|00004920| 0d 09 23 69 6e 63 6c 75 | 64 65 20 3c 53 6c 6f 74 |..#inclu|de <Slot|
|00004930| 73 2e 68 3e 0d 09 23 69 | 6e 63 6c 75 64 65 20 3c |s.h>..#i|nclude <|
|00004940| 53 6f 75 6e 64 2e 68 3e | 0d 09 23 69 66 20 54 48 |Sound.h>|..#if TH|
|00004950| 49 4e 4b 5f 43 20 26 26 | 20 21 55 4e 49 56 45 52 |INK_C &&| !UNIVER|
|00004960| 53 41 4c 5f 48 45 41 44 | 45 52 53 0d 09 09 23 69 |SAL_HEAD|ERS...#i|
|00004970| 6e 63 6c 75 64 65 20 3c | 70 61 73 63 61 6c 2e 68 |nclude <|pascal.h|
|00004980| 3e 09 2f 2a 20 43 74 6f | 50 53 74 72 28 29 20 61 |>./* Cto|PStr() a|
|00004990| 6e 64 20 50 74 6f 43 53 | 74 72 28 29 20 2a 2f 0d |nd PtoCS|tr() */.|
|000049a0| 09 09 23 69 66 6e 64 65 | 66 20 63 32 70 73 74 72 |..#ifnde|f c2pstr|
|000049b0| 0d 09 09 09 23 64 65 66 | 69 6e 65 20 63 32 70 73 |....#def|ine c2ps|
|000049c0| 74 72 28 73 29 20 43 74 | 6f 50 73 74 72 28 73 29 |tr(s) Ct|oPstr(s)|
|000049d0| 0d 09 09 09 23 64 65 66 | 69 6e 65 20 70 32 63 73 |....#def|ine p2cs|
|000049e0| 74 72 28 73 29 20 50 74 | 6f 43 73 74 72 28 73 29 |tr(s) Pt|oCstr(s)|
|000049f0| 0d 09 09 23 65 6e 64 69 | 66 0d 09 23 65 6c 73 65 |...#endi|f..#else|
|00004a00| 0d 09 09 23 69 6e 63 6c | 75 64 65 20 3c 53 74 72 |...#incl|ude <Str|
|00004a10| 69 6e 67 73 2e 68 3e 2f | 2a 20 63 32 70 73 74 72 |ings.h>/|* c2pstr|
|00004a20| 28 29 20 61 6e 64 20 70 | 32 63 73 74 72 28 29 20 |() and p|2cstr() |
|00004a30| 2a 2f 0d 09 09 23 64 65 | 66 69 6e 65 20 43 74 6f |*/...#de|fine Cto|
|00004a40| 50 73 74 72 20 63 32 70 | 73 74 72 0d 09 09 23 64 |Pstr c2p|str...#d|
|00004a50| 65 66 69 6e 65 20 50 74 | 6f 43 73 74 72 20 70 32 |efine Pt|oCstr p2|
|00004a60| 63 73 74 72 0d 09 23 65 | 6e 64 69 66 0d 09 23 69 |cstr..#e|ndif..#i|
|00004a70| 6e 63 6c 75 64 65 20 3c | 54 69 6d 65 72 2e 68 3e |nclude <|Timer.h>|
|00004a80| 09 09 2f 2a 20 20 72 65 | 71 75 69 72 65 64 20 2a |../* re|quired *|
|00004a90| 2f 0d 09 23 69 6e 63 6c | 75 64 65 20 3c 54 6f 6f |/..#incl|ude <Too|
|00004aa0| 6c 55 74 69 6c 73 2e 68 | 3e 0d 09 23 69 6e 63 6c |lUtils.h|>..#incl|
|00004ab0| 75 64 65 20 3c 54 72 61 | 70 73 2e 68 3e 0d 09 23 |ude <Tra|ps.h>..#|
|00004ac0| 69 6e 63 6c 75 64 65 20 | 3c 56 69 64 65 6f 2e 68 |include |<Video.h|
|00004ad0| 3e 0d 09 23 69 6e 63 6c | 75 64 65 20 3c 57 69 6e |>..#incl|ude <Win|
|00004ae0| 64 6f 77 73 2e 68 3e 09 | 2f 2a 20 20 72 65 71 75 |dows.h>.|/* requ|
|00004af0| 69 72 65 64 20 2a 2f 0d | 09 2f 2a 0d 09 4f 6c 64 |ired */.|./*..Old|
|00004b00| 20 4d 65 6d 6f 72 79 2e | 68 20 68 65 61 64 65 72 | Memory.|h header|
|00004b10| 20 66 69 6c 65 73 2c 20 | 62 65 66 6f 72 65 20 41 | files, |before A|
|00004b20| 70 70 6c 65 27 73 20 55 | 6e 69 76 65 72 73 61 6c |pple's U|niversal|
|00004b30| 20 48 65 61 64 65 72 73 | 2c 20 64 6f 6e 27 74 20 | Headers|, don't |
|00004b40| 64 65 66 69 6e 65 20 74 | 68 65 20 6e 65 77 0d 09 |define t|he new..|
|00004b50| 42 6c 6f 63 6b 4d 6f 76 | 65 44 61 74 61 28 29 2c |BlockMov|eData(),|
|00004b60| 20 73 6f 20 77 65 20 64 | 6f 20 69 74 20 68 65 72 | so we d|o it her|
|00004b70| 65 2c 20 74 6f 20 72 65 | 74 61 69 6e 20 63 6f 6d |e, to re|tain com|
|00004b80| 70 61 62 69 6c 69 74 79 | 20 77 69 74 68 20 74 68 |pability| with th|
|00004b90| 65 20 6f 6c 64 20 68 65 | 61 64 65 72 20 66 69 6c |e old he|ader fil|
|00004ba0| 65 73 2e 0d 09 2a 2f 0d | 09 23 69 66 20 21 55 4e |es...*/.|.#if !UN|
|00004bb0| 49 56 45 52 53 41 4c 5f | 48 45 41 44 45 52 53 0d |IVERSAL_|HEADERS.|
|00004bc0| 09 09 23 70 72 61 67 6d | 61 20 70 61 72 61 6d 65 |..#pragm|a parame|
|00004bd0| 74 65 72 20 42 6c 6f 63 | 6b 4d 6f 76 65 44 61 74 |ter Bloc|kMoveDat|
|00004be0| 61 28 5f 5f 41 30 2c 5f | 5f 41 31 2c 5f 5f 44 30 |a(__A0,_|_A1,__D0|
|00004bf0| 29 0d 09 09 65 78 74 65 | 72 6e 20 70 61 73 63 61 |)...exte|rn pasca|
|00004c00| 6c 20 76 6f 69 64 20 42 | 6c 6f 63 6b 4d 6f 76 65 |l void B|lockMove|
|00004c10| 44 61 74 61 28 63 6f 6e | 73 74 20 76 6f 69 64 20 |Data(con|st void |
|00004c20| 2a 73 72 63 50 74 72 2c | 76 6f 69 64 20 2a 64 65 |*srcPtr,|void *de|
|00004c30| 73 74 50 74 72 2c 53 69 | 7a 65 20 62 79 74 65 43 |stPtr,Si|ze byteC|
|00004c40| 6f 75 6e 74 29 3d 30 78 | 41 32 32 45 3b 0d 09 23 |ount)=0x|A22E;..#|
|00004c50| 65 6e 64 69 66 0d 23 65 | 6e 64 69 66 0d 0d 2f 2a |endif.#e|ndif../*|
|00004c60| 0d 54 68 69 73 20 72 65 | 64 65 66 69 6e 65 73 20 |.This re|defines |
|00004c70| 74 68 65 20 73 74 61 6e | 64 61 72 64 20 43 20 66 |the stan|dard C f|
|00004c80| 75 6e 63 74 69 6f 6e 73 | 2c 20 6d 61 6c 6c 6f 63 |unctions|, malloc|
|00004c90| 2c 20 65 74 63 2e 20 74 | 6f 20 69 6e 73 74 65 61 |, etc. t|o instea|
|00004ca0| 64 20 63 61 6c 6c 20 41 | 70 70 6c 65 27 73 0d 63 |d call A|pple's.c|
|00004cb0| 6f 72 72 65 73 70 6f 6e | 64 69 6e 67 20 72 6f 75 |orrespon|ding rou|
|00004cc0| 74 69 6e 65 73 2c 20 65 | 2e 67 2e 20 4e 65 77 50 |tines, e|.g. NewP|
|00004cd0| 74 72 2e 20 54 68 65 20 | 54 48 49 4e 4b 20 43 20 |tr. The |THINK C |
|00004ce0| 6d 65 6d 6f 72 79 20 6d | 61 6e 61 67 65 6d 65 6e |memory m|anagemen|
|00004cf0| 74 20 72 6f 75 74 69 6e | 65 73 20 61 72 65 20 0d |t routin|es are .|
|00004d00| 70 6f 6f 72 20 62 65 63 | 61 75 73 65 20 74 68 65 |poor bec|ause the|
|00004d10| 79 20 61 72 65 20 62 61 | 64 20 61 62 6f 75 74 20 |y are ba|d about |
|00004d20| 66 72 65 65 69 6e 67 20 | 73 70 61 63 65 2c 20 74 |freeing |space, t|
|00004d30| 65 6e 64 69 6e 67 20 74 | 6f 20 66 72 61 67 6d 65 |ending t|o fragme|
|00004d40| 6e 74 20 74 68 65 20 66 | 72 65 65 20 73 70 61 63 |nt the f|ree spac|
|00004d50| 65 2e 20 0d 2a 2f 0d 23 | 69 66 20 54 48 49 4e 4b |e. .*/.#|if THINK|
|00004d60| 5f 43 20 26 26 20 21 64 | 65 66 69 6e 65 64 28 53 |_C && !d|efined(S|
|00004d70| 59 4d 41 4e 54 45 43 5f | 43 29 0d 09 23 69 6e 63 |YMANTEC_|C)..#inc|
|00004d80| 6c 75 64 65 20 22 4d 61 | 63 4d 65 6d 6f 72 79 2e |lude "Ma|cMemory.|
|00004d90| 68 22 0d 23 65 6e 64 69 | 66 0d 0d 2f 2a 0d 4d 41 |h".#endi|f../*.MA|
|00004da0| 54 4c 41 42 20 41 4e 44 | 20 54 48 45 20 4e 45 57 |TLAB AND| THE NEW|
|00004db0| 4c 49 4e 45 20 43 48 41 | 52 41 43 54 45 52 0d 49 |LINE CHA|RACTER.I|
|00004dc0| 6e 20 6d 6f 73 74 20 43 | 20 65 6e 76 69 72 6f 6e |n most C| environ|
|00004dd0| 6d 65 6e 74 73 20 74 68 | 65 20 6e 65 77 6c 69 6e |ments th|e newlin|
|00004de0| 65 20 63 68 61 72 61 63 | 74 65 72 20 69 73 20 27 |e charac|ter is '|
|00004df0| 5c 6e 27 20 28 61 73 63 | 69 69 20 31 30 29 2e 20 |\n' (asc|ii 10). |
|00004e00| 49 6e 20 41 70 70 6c 65 | 27 73 0d 77 69 73 64 6f |In Apple|'s.wisdo|
|00004e10| 6d 20 74 68 65 79 20 63 | 68 6f 73 65 20 74 6f 20 |m they c|hose to |
|00004e20| 73 65 70 61 72 61 74 65 | 20 6c 69 6e 65 73 20 69 |separate| lines i|
|00004e30| 6e 20 4d 61 63 69 6e 74 | 6f 73 68 20 66 69 6c 65 |n Macint|osh file|
|00004e40| 73 20 77 69 74 68 20 74 | 68 65 20 61 73 63 69 69 |s with t|he ascii|
|00004e50| 20 31 33 0d 63 68 61 72 | 61 63 74 65 72 2c 20 77 | 13.char|acter, w|
|00004e60| 68 69 63 68 20 69 73 20 | 75 73 75 61 6c 6c 79 20 |hich is |usually |
|00004e70| 63 61 6c 6c 65 64 20 74 | 68 65 20 72 65 74 75 72 |called t|he retur|
|00004e80| 6e 20 63 68 61 72 61 63 | 74 65 72 20 27 5c 72 27 |n charac|ter '\r'|
|00004e90| 2e 20 53 74 61 6e 64 61 | 72 64 20 43 0d 73 70 65 |. Standa|rd C.spe|
|00004ea0| 63 69 66 69 65 73 20 74 | 68 61 74 20 74 68 65 20 |cifies t|hat the |
|00004eb0| 73 74 64 69 6f 20 6c 69 | 62 72 61 72 79 20 77 69 |stdio li|brary wi|
|00004ec0| 6c 6c 20 75 73 65 20 27 | 5c 6e 27 20 61 73 20 74 |ll use '|\n' as t|
|00004ed0| 68 65 20 6e 65 77 6c 69 | 6e 65 20 63 68 61 72 61 |he newli|ne chara|
|00004ee0| 63 74 65 72 2e 20 54 68 | 69 73 0d 70 6f 74 65 6e |cter. Th|is.poten|
|00004ef0| 74 69 61 6c 6c 79 20 63 | 72 65 61 74 65 73 20 61 |tially c|reates a|
|00004f00| 20 63 6f 6d 70 61 74 69 | 62 69 6c 69 74 79 20 70 | compati|bility p|
|00004f10| 72 6f 62 6c 65 6d 20 62 | 65 74 77 65 65 6e 20 4d |roblem b|etween M|
|00004f20| 61 63 20 43 20 70 72 6f | 67 72 61 6d 73 20 61 6e |ac C pro|grams an|
|00004f30| 64 20 43 0d 70 72 6f 67 | 72 61 6d 73 20 77 72 69 |d C.prog|rams wri|
|00004f40| 74 74 65 6e 20 66 6f 72 | 20 74 68 65 20 72 65 73 |tten for| the res|
|00004f50| 74 20 6f 66 20 74 68 65 | 20 77 6f 72 6c 64 27 73 |t of the| world's|
|00004f60| 20 63 6f 6d 70 75 74 65 | 72 73 2c 20 73 69 6e 63 | compute|rs, sinc|
|00004f70| 65 20 6f 6e 65 20 77 61 | 6e 74 73 20 61 6e 79 20 |e one wa|nts any |
|00004f80| 74 65 78 74 0d 66 69 6c | 65 73 20 74 68 65 79 20 |text.fil|es they |
|00004f90| 70 72 6f 64 75 63 65 20 | 74 6f 20 62 65 20 61 70 |produce |to be ap|
|00004fa0| 70 72 6f 70 72 69 61 74 | 65 20 74 6f 20 74 68 65 |propriat|e to the|
|00004fb0| 20 6c 6f 63 61 6c 20 65 | 6e 76 69 72 6f 6e 6d 65 | local e|nvironme|
|00004fc0| 6e 74 2e 20 42 6f 74 68 | 20 4d 50 57 20 61 6e 64 |nt. Both| MPW and|
|00004fd0| 0d 54 48 49 4e 4b 20 43 | 20 72 65 73 6f 6c 76 65 |.THINK C| resolve|
|00004fe0| 20 74 68 65 20 70 72 6f | 62 6c 65 6d 20 62 65 68 | the pro|blem beh|
|00004ff0| 69 6e 64 20 74 68 65 20 | 73 63 65 6e 65 73 2c 20 |ind the |scenes, |
|00005000| 62 75 74 20 74 68 65 79 | 20 64 6f 20 69 74 20 69 |but they| do it i|
|00005010| 6e 20 64 69 66 66 65 72 | 65 6e 74 20 77 61 79 73 |n differ|ent ways|
|00005020| 2e 0d 4d 50 57 20 72 65 | 64 65 66 69 6e 65 73 20 |..MPW re|defines |
|00005030| 74 68 65 20 61 73 73 6f | 63 69 61 74 69 6f 6e 20 |the asso|ciation |
|00005040| 62 65 74 77 65 65 6e 20 | 73 79 6d 62 6f 6c 69 63 |between |symbolic|
|00005050| 20 6e 61 6d 65 73 20 61 | 6e 64 20 63 68 61 72 61 | names a|nd chara|
|00005060| 63 74 65 72 20 63 6f 64 | 65 73 2c 20 6d 61 6b 69 |cter cod|es, maki|
|00005070| 6e 67 0d 27 5c 6e 27 20 | 62 65 20 31 33 20 61 6e |ng.'\n' |be 13 an|
|00005080| 64 20 27 5c 72 27 20 62 | 65 20 31 30 2e 20 54 48 |d '\r' b|e 10. TH|
|00005090| 49 4e 4b 20 43 20 69 6e | 73 74 65 61 64 20 6d 6f |INK C in|stead mo|
|000050a0| 64 69 66 69 65 73 20 74 | 68 65 20 73 74 64 69 6f |difies t|he stdio|
|000050b0| 20 6c 69 62 72 61 72 79 | 20 73 6f 20 74 68 61 74 | library| so that|
|000050c0| 0d 72 65 61 64 73 20 61 | 6e 64 20 77 72 69 74 65 |.reads a|nd write|
|000050d0| 73 20 74 6f 20 61 20 22 | 74 65 78 74 22 20 28 69 |s to a "|text" (i|
|000050e0| 2e 65 2e 20 6e 6f 74 20 | 62 69 6e 61 72 79 29 20 |.e. not |binary) |
|000050f0| 73 74 72 65 61 6d 20 61 | 72 65 20 74 72 61 6e 73 |stream a|re trans|
|00005100| 6c 61 74 65 64 2c 20 65 | 78 63 68 61 6e 67 69 6e |lated, e|xchangin|
|00005110| 67 0d 63 68 61 72 61 63 | 74 65 72 20 63 6f 64 65 |g.charac|ter code|
|00005120| 73 20 31 30 20 61 6e 64 | 20 31 33 2e 20 42 6f 74 |s 10 and| 13. Bot|
|00005130| 68 20 73 6f 6c 75 74 69 | 6f 6e 73 20 77 6f 72 6b |h soluti|ons work|
|00005140| 2e 20 48 6f 77 65 76 65 | 72 2c 20 77 68 65 6e 20 |. Howeve|r, when |
|00005150| 77 65 20 75 73 65 20 54 | 48 49 4e 4b 20 43 20 74 |we use T|HINK C t|
|00005160| 6f 0d 63 72 65 61 74 65 | 20 63 6f 64 65 20 72 65 |o.create| code re|
|00005170| 73 6f 75 72 63 65 73 20 | 66 6f 72 20 4d 41 54 4c |sources |for MATL|
|00005180| 41 42 20 77 65 20 61 72 | 65 20 66 6f 72 63 65 64 |AB we ar|e forced|
|00005190| 20 74 6f 20 75 73 65 20 | 74 68 65 20 4d 50 57 20 | to use |the MPW |
|000051a0| 73 74 64 69 6f 20 6c 69 | 62 72 61 72 79 20 74 68 |stdio li|brary th|
|000051b0| 61 74 0d 69 73 20 62 75 | 69 6c 74 20 69 6e 74 6f |at.is bu|ilt into|
|000051c0| 20 4d 41 54 4c 41 42 2e | 20 55 6e 66 6f 72 74 75 | MATLAB.| Unfortu|
|000051d0| 6e 61 74 65 6c 79 20 74 | 68 69 73 20 62 79 70 61 |nately t|his bypa|
|000051e0| 73 73 65 73 20 62 6f 74 | 68 20 63 6f 6d 70 69 6c |sses bot|h compil|
|000051f0| 65 72 73 27 20 66 69 78 | 65 73 20 74 6f 20 74 68 |ers' fix|es to th|
|00005200| 65 0d 6e 65 77 6c 69 6e | 65 20 70 72 6f 62 6c 65 |e.newlin|e proble|
|00005210| 6d 2e 20 54 68 65 20 70 | 72 6f 62 6c 65 6d 20 61 |m. The p|roblem a|
|00005220| 66 66 65 63 74 73 20 65 | 76 65 72 79 20 73 69 6e |ffects e|very sin|
|00005230| 67 6c 65 20 74 65 78 74 | 20 69 2f 6f 20 6f 70 65 |gle text| i/o ope|
|00005240| 72 61 74 69 6f 6e 2c 20 | 65 2e 67 2e 20 65 76 65 |ration, |e.g. eve|
|00005250| 72 79 0d 70 72 69 6e 74 | 66 20 61 6e 64 20 73 63 |ry.print|f and sc|
|00005260| 61 6e 66 2e 20 41 6c 61 | 73 2c 20 74 68 65 72 65 |anf. Ala|s, there|
|00005270| 20 69 73 20 6e 6f 20 77 | 61 79 20 74 6f 20 67 65 | is no w|ay to ge|
|00005280| 74 20 74 68 65 20 70 72 | 65 2d 70 72 6f 63 65 73 |t the pr|e-proces|
|00005290| 73 6f 72 20 74 6f 20 72 | 65 64 65 66 69 6e 65 20 |sor to r|edefine |
|000052a0| 2f 6e 0d 61 6e 64 20 2f | 72 2e 0d 0d 4f 75 72 20 |/n.and /|r...Our |
|000052b0| 71 75 69 63 6b 20 66 69 | 78 20 69 73 20 74 6f 20 |quick fi|x is to |
|000052c0| 63 72 65 61 74 65 20 61 | 20 6d 61 63 72 6f 20 63 |create a| macro c|
|000052d0| 61 6c 6c 65 64 20 4e 4c | 20 74 68 61 74 20 69 73 |alled NL| that is|
|000052e0| 20 6e 6f 72 6d 61 6c 6c | 79 20 64 65 66 69 6e 65 | normall|y define|
|000052f0| 64 20 61 73 20 74 68 65 | 0d 6e 65 77 6c 69 6e 65 |d as the|.newline|
|00005300| 20 73 74 72 69 6e 67 20 | 22 5c 6e 22 2c 20 62 75 | string |"\n", bu|
|00005310| 74 20 77 68 69 63 68 20 | 69 73 20 69 6e 73 74 65 |t which |is inste|
|00005320| 61 64 20 64 65 66 69 6e | 65 64 20 61 73 20 22 5c |ad defin|ed as "\|
|00005330| 30 31 35 22 20 28 69 2e | 65 2e 20 61 73 63 69 69 |015" (i.|e. ascii|
|00005340| 20 31 33 29 20 77 68 65 | 6e 0d 4d 41 54 4c 41 42 | 13) whe|n.MATLAB|
|00005350| 20 69 73 20 74 72 75 65 | 2e 20 50 72 6f 67 72 61 | is true|. Progra|
|00005360| 6d 73 20 73 75 63 68 20 | 61 73 20 41 73 73 69 67 |ms such |as Assig|
|00005370| 6e 2e 63 20 74 68 61 74 | 20 68 61 76 65 20 72 65 |n.c that| have re|
|00005380| 70 6c 61 63 65 64 20 61 | 6c 6c 20 69 6e 73 74 61 |placed a|ll insta|
|00005390| 6e 63 65 73 20 6f 66 0d | 22 5c 6e 22 20 62 79 20 |nces of.|"\n" by |
|000053a0| 4e 4c 20 77 69 6c 6c 20 | 74 68 65 6e 20 77 6f 72 |NL will |then wor|
|000053b0| 6b 20 77 68 65 74 68 65 | 72 20 6f 72 20 6e 6f 74 |k whethe|r or not|
|000053c0| 20 4d 41 54 4c 41 42 20 | 69 73 20 74 72 75 65 2e | MATLAB |is true.|
|000053d0| 20 54 68 65 20 6f 62 76 | 69 6f 75 73 20 64 72 61 | The obv|ious dra|
|000053e0| 77 62 61 63 6b 20 69 73 | 0d 74 68 61 74 20 74 68 |wback is|.that th|
|000053f0| 69 73 20 71 75 69 63 6b | 20 73 6f 6c 75 74 69 6f |is quick| solutio|
|00005400| 6e 20 72 65 71 75 69 72 | 65 73 20 74 68 65 73 65 |n requir|es these|
|00005410| 20 6d 6f 64 69 66 69 63 | 61 74 69 6f 6e 73 20 74 | modific|ations t|
|00005420| 6f 20 74 68 65 20 73 6f | 75 72 63 65 20 66 69 6c |o the so|urce fil|
|00005430| 65 73 2e 0d 2a 2f 0d 23 | 69 66 20 4d 41 54 4c 41 |es..*/.#|if MATLA|
|00005440| 42 20 26 26 20 54 48 49 | 4e 4b 5f 43 09 2f 2a 20 |B && THI|NK_C./* |
|00005450| 51 75 69 63 6b 20 66 69 | 78 20 2a 2f 0d 09 23 64 |Quick fi|x */..#d|
|00005460| 65 66 69 6e 65 20 4e 4c | 20 22 5c 72 22 0d 09 23 |efine NL| "\r"..#|
|00005470| 64 65 66 69 6e 65 20 4e | 45 57 4c 49 4e 45 20 27 |define N|EWLINE '|
|00005480| 5c 72 27 0d 23 65 6c 73 | 65 0d 09 23 64 65 66 69 |\r'.#els|e..#defi|
|00005490| 6e 65 20 4e 4c 20 22 5c | 6e 22 09 09 2f 2a 20 74 |ne NL "\|n"../* t|
|000054a0| 68 65 20 73 74 61 6e 64 | 61 72 64 20 6e 65 77 2d |he stand|ard new-|
|000054b0| 6c 69 6e 65 20 73 74 72 | 69 6e 67 20 2a 2f 0d 09 |line str|ing */..|
|000054c0| 23 64 65 66 69 6e 65 20 | 4e 45 57 4c 49 4e 45 20 |#define |NEWLINE |
|000054d0| 27 5c 6e 27 0d 23 65 6e | 64 69 66 0d 0d 2f 2a 0d |'\n'.#en|dif../*.|
|000054e0| 54 52 55 45 20 61 6e 64 | 20 46 41 4c 53 45 0d 2a |TRUE and| FALSE.*|
|000054f0| 2f 0d 23 69 66 6e 64 65 | 66 20 54 52 55 45 0d 09 |/.#ifnde|f TRUE..|
|00005500| 23 64 65 66 69 6e 65 20 | 46 41 4c 53 45 09 30 0d |#define |FALSE.0.|
|00005510| 09 23 64 65 66 69 6e 65 | 20 54 52 55 45 09 31 0d |.#define| TRUE.1.|
|00005520| 23 65 6e 64 69 66 0d 0d | 2f 2a 0d 4e 41 4e 20 26 |#endif..|/*.NAN &|
|00005530| 20 49 4e 46 0d 49 66 20 | 79 6f 75 27 72 65 20 75 | INF.If |you're u|
|00005540| 73 69 6e 67 20 4e 41 4e | 20 61 6e 64 20 49 4e 46 |sing NAN| and INF|
|00005550| 20 79 6f 75 27 6c 6c 20 | 62 65 20 69 6e 74 65 72 | you'll |be inter|
|00005560| 65 73 74 65 64 20 69 6e | 20 74 68 65 20 49 73 4e |ested in| the IsN|
|00005570| 61 6e 28 29 2c 20 49 73 | 49 6e 66 28 29 2c 20 61 |an(), Is|Inf(), a|
|00005580| 6e 64 0d 49 73 46 69 6e | 69 74 65 28 29 20 64 65 |nd.IsFin|ite() de|
|00005590| 66 69 6e 69 74 69 6f 6e | 73 20 26 20 70 72 6f 74 |finition|s & prot|
|000055a0| 6f 74 79 70 65 73 20 62 | 65 6c 6f 77 2e 20 0d 41 |otypes b|elow. .A|
|000055b0| 70 70 6c 65 27 73 20 66 | 70 2e 68 20 68 65 61 64 |pple's f|p.h head|
|000055c0| 65 72 20 64 65 66 69 6e | 65 73 20 69 73 6e 61 6e |er defin|es isnan|
|000055d0| 28 29 20 61 6e 64 20 69 | 73 66 69 6e 69 74 65 28 |() and i|sfinite(|
|000055e0| 29 2e 0d 41 70 70 6c 65 | 27 73 20 68 65 61 64 65 |)..Apple|'s heade|
|000055f0| 72 20 66 69 6c 65 73 20 | 6d 61 74 68 2e 68 20 61 |r files |math.h a|
|00005600| 6e 64 20 66 70 2e 68 20 | 62 6f 74 68 20 64 65 66 |nd fp.h |both def|
|00005610| 69 6e 65 20 48 55 47 45 | 5f 56 41 4c 20 61 6e 64 |ine HUGE|_VAL and|
|00005620| 20 70 69 2e 0d 66 70 2e | 68 20 61 6c 73 6f 20 64 | pi..fp.|h also d|
|00005630| 65 66 69 6e 65 73 20 49 | 4e 46 49 4e 49 54 59 2c |efines I|NFINITY,|
|00005640| 20 4e 41 4e 2c 20 69 73 | 66 69 6e 69 74 65 28 29 | NAN, is|finite()|
|00005650| 2c 20 61 6e 64 20 69 73 | 6e 61 6e 28 29 2e 0d 2a |, and is|nan()..*|
|00005660| 2f 0d 23 69 66 20 21 64 | 65 66 69 6e 65 64 28 49 |/.#if !d|efined(I|
|00005670| 4e 46 29 0d 09 23 64 65 | 66 69 6e 65 20 49 4e 46 |NF)..#de|fine INF|
|00005680| 20 48 55 47 45 5f 56 41 | 4c 09 2f 2a 20 48 55 47 | HUGE_VA|L./* HUG|
|00005690| 45 5f 56 41 4c 20 69 73 | 20 64 65 66 69 6e 65 64 |E_VAL is| defined|
|000056a0| 20 69 6e 20 6d 61 74 68 | 2e 68 20 61 6e 64 20 66 | in math|.h and f|
|000056b0| 70 2e 68 20 2a 2f 0d 23 | 65 6e 64 69 66 0d 23 69 |p.h */.#|endif.#i|
|000056c0| 66 20 21 64 65 66 69 6e | 65 64 28 4e 41 4e 29 0d |f !defin|ed(NAN).|
|000056d0| 2f 2a 09 23 64 65 66 69 | 6e 65 20 4e 41 4e 09 28 |/*.#defi|ne NAN.(|
|000056e0| 30 2e 30 2f 30 2e 30 29 | 09 2a 2f 09 2f 2a 20 65 |0.0/0.0)|.*/./* e|
|000056f0| 76 61 6c 75 61 74 65 64 | 20 61 74 20 72 75 6e 74 |valuated| at runt|
|00005700| 69 6d 65 20 2a 2f 0d 09 | 23 64 65 66 69 6e 65 20 |ime */..|#define |
|00005710| 4e 41 4e 09 4e 61 6e 09 | 09 09 2f 2a 20 67 6c 6f |NAN.Nan.|../* glo|
|00005720| 62 61 6c 20 64 65 66 69 | 6e 65 64 20 69 6e 20 4e |bal defi|ned in N|
|00005730| 61 6e 2e 63 20 2a 2f 0d | 23 65 6e 64 69 66 0d 0d |an.c */.|#endif..|
|00005740| 2f 2a 0d 4e 55 4d 45 52 | 49 43 41 4c 20 43 4f 4e |/*.NUMER|ICAL CON|
|00005750| 53 54 41 4e 54 53 0d 49 | 74 27 73 20 73 61 64 20 |STANTS.I|t's sad |
|00005760| 74 6f 20 73 61 79 2c 20 | 62 75 74 20 54 48 49 4e |to say, |but THIN|
|00005770| 4b 20 43 20 35 2e 30 32 | 20 6c 6f 73 65 73 20 74 |K C 5.02| loses t|
|00005780| 77 6f 20 62 69 74 73 20 | 6f 66 20 70 72 65 63 69 |wo bits |of preci|
|00005790| 73 69 6f 6e 20 63 6f 6e | 76 65 72 74 69 6e 67 20 |sion con|verting |
|000057a0| 62 65 74 77 65 65 6e 0d | 64 6f 75 62 6c 65 73 20 |between.|doubles |
|000057b0| 61 6e 64 20 61 73 63 69 | 69 20 74 65 78 74 2c 20 |and asci|i text, |
|000057c0| 69 6e 20 65 69 74 68 65 | 72 20 64 69 72 65 63 74 |in eithe|r direct|
|000057d0| 69 6f 6e 2e 20 54 68 75 | 73 20 79 6f 75 20 77 69 |ion. Thu|s you wi|
|000057e0| 6c 6c 20 6f 62 74 61 69 | 6e 20 6d 6f 72 65 20 61 |ll obtai|n more a|
|000057f0| 63 63 75 72 61 74 65 0d | 72 65 73 75 6c 74 73 20 |ccurate.|results |
|00005800| 62 79 20 63 6f 6d 70 75 | 74 69 6e 67 20 74 68 65 |by compu|ting the|
|00005810| 20 6e 75 6d 65 72 69 63 | 61 6c 20 63 6f 6e 73 74 | numeric|al const|
|00005820| 61 6e 74 73 20 62 65 6c | 6f 77 20 61 74 20 72 75 |ants bel|ow at ru|
|00005830| 6e 74 69 6d 65 20 72 61 | 74 68 65 72 20 74 68 61 |ntime ra|ther tha|
|00005840| 6e 20 75 73 69 6e 67 0d | 74 68 65 73 65 20 70 72 |n using.|these pr|
|00005850| 65 64 65 66 69 6e 65 64 | 20 63 6f 6e 73 74 61 6e |edefined| constan|
|00005860| 74 73 2e 20 54 68 65 20 | 41 4e 53 49 20 4e 75 6d |ts. The |ANSI Num|
|00005870| 65 72 69 63 61 6c 20 43 | 20 45 78 74 65 6e 73 69 |erical C| Extensi|
|00005880| 6f 6e 73 20 67 72 6f 75 | 70 20 69 73 20 6d 6f 76 |ons grou|p is mov|
|00005890| 69 6e 67 20 74 6f 0d 72 | 65 71 75 69 72 65 20 43 |ing to.r|equire C|
|000058a0| 20 63 6f 6d 70 69 6c 65 | 72 73 20 74 6f 20 70 72 | compile|rs to pr|
|000058b0| 65 73 65 72 76 65 20 70 | 72 65 63 69 73 69 6f 6e |eserve p|recision|
|000058c0| 2c 20 73 6f 20 74 68 65 | 72 65 20 69 73 20 68 6f |, so the|re is ho|
|000058d0| 70 65 20 66 6f 72 20 74 | 68 65 20 66 75 74 75 72 |pe for t|he futur|
|000058e0| 65 2e 20 4f 66 0d 63 6f | 75 72 73 65 20 6d 6f 73 |e. Of.co|urse mos|
|000058f0| 74 20 61 70 70 6c 69 63 | 61 74 69 6f 6e 73 20 77 |t applic|ations w|
|00005900| 6f 75 6c 64 20 6e 65 76 | 65 72 20 6e 6f 74 69 63 |ould nev|er notic|
|00005910| 65 20 61 20 6c 6f 73 73 | 20 6f 66 20 74 77 6f 20 |e a loss| of two |
|00005920| 62 69 74 73 20 70 72 65 | 63 69 73 69 6f 6e 20 6f |bits pre|cision o|
|00005930| 75 74 20 6f 66 0d 74 68 | 65 20 74 6f 74 61 6c 20 |ut of.th|e total |
|00005940| 64 6f 75 62 6c 65 20 70 | 72 65 63 69 73 69 6f 6e |double p|recision|
|00005950| 20 67 69 76 65 6e 20 62 | 79 20 74 68 65 20 36 34 | given b|y the 64|
|00005960| 20 62 69 74 73 20 69 6e | 20 74 68 65 20 6d 61 6e | bits in| the man|
|00005970| 74 69 73 73 61 2e 0d 2a | 2f 0d 23 69 66 20 21 64 |tissa..*|/.#if !d|
|00005980| 65 66 69 6e 65 64 28 50 | 49 29 0d 09 23 69 66 20 |efined(P|I)..#if |
|00005990| 55 4e 49 56 45 52 53 41 | 4c 5f 48 45 41 44 45 52 |UNIVERSA|L_HEADER|
|000059a0| 53 3e 3d 32 0d 09 09 23 | 64 65 66 69 6e 65 20 50 |S>=2...#|define P|
|000059b0| 49 09 09 70 69 09 09 09 | 09 09 09 2f 2a 20 70 69 |I..pi...|.../* pi|
|000059c0| 20 69 73 20 64 65 66 69 | 6e 65 64 20 69 6e 20 6d | is defi|ned in m|
|000059d0| 61 74 68 2e 68 20 61 6e | 64 20 66 70 2e 68 20 2a |ath.h an|d fp.h *|
|000059e0| 2f 0d 09 23 65 6c 73 65 | 0d 09 09 23 64 65 66 69 |/..#else|...#defi|
|000059f0| 6e 65 20 50 49 09 09 33 | 2e 31 34 31 35 39 32 36 |ne PI..3|.1415926|
|00005a00| 35 33 35 38 39 37 39 33 | 32 33 38 35 09 2f 2a 20 |53589793|2385./* |
|00005a10| 63 6f 6d 70 75 74 65 64 | 20 69 6e 20 4d 61 74 68 |computed| in Math|
|00005a20| 65 6d 61 74 69 63 61 20 | 2a 2f 0d 09 23 65 6e 64 |ematica |*/..#end|
|00005a30| 69 66 0d 23 65 6e 64 69 | 66 0d 23 69 66 20 21 64 |if.#endi|f.#if !d|
|00005a40| 65 66 69 6e 65 64 28 4c | 4f 47 50 49 29 0d 09 23 |efined(L|OGPI)..#|
|00005a50| 64 65 66 69 6e 65 20 4c | 4f 47 50 49 09 31 2e 31 |define L|OGPI.1.1|
|00005a60| 34 34 37 32 39 38 38 35 | 38 34 39 34 30 30 31 37 |44729885|84940017|
|00005a70| 34 31 34 09 2f 2a 20 63 | 6f 6d 70 75 74 65 64 20 |414./* c|omputed |
|00005a80| 69 6e 20 4d 61 74 68 65 | 6d 61 74 69 63 61 20 2a |in Mathe|matica *|
|00005a90| 2f 0d 23 65 6e 64 69 66 | 0d 23 69 66 20 21 64 65 |/.#endif|.#if !de|
|00005aa0| 66 69 6e 65 64 28 4c 4f | 47 32 29 0d 09 23 64 65 |fined(LO|G2)..#de|
|00005ab0| 66 69 6e 65 20 4c 4f 47 | 32 09 30 2e 36 39 33 31 |fine LOG|2.0.6931|
|00005ac0| 34 37 31 38 30 35 35 39 | 39 34 35 33 30 39 34 32 |47180559|94530942|
|00005ad0| 09 2f 2a 20 63 6f 6d 70 | 75 74 65 64 20 69 6e 20 |./* comp|uted in |
|00005ae0| 4d 61 74 68 65 6d 61 74 | 69 63 61 20 2a 2f 0d 23 |Mathemat|ica */.#|
|00005af0| 65 6e 64 69 66 0d 23 69 | 66 20 21 64 65 66 69 6e |endif.#i|f !defin|
|00005b00| 65 64 28 4c 4f 47 31 30 | 29 0d 09 23 64 65 66 69 |ed(LOG10|)..#defi|
|00005b10| 6e 65 20 4c 4f 47 31 30 | 09 32 2e 33 30 32 35 38 |ne LOG10|.2.30258|
|00005b20| 35 30 39 32 39 39 34 30 | 34 35 36 38 34 30 32 09 |50929940|4568402.|
|00005b30| 2f 2a 20 63 6f 6d 70 75 | 74 65 64 20 69 6e 20 4d |/* compu|ted in M|
|00005b40| 61 74 68 65 6d 61 74 69 | 63 61 20 2a 2f 0d 23 65 |athemati|ca */.#e|
|00005b50| 6e 64 69 66 0d 0d 23 69 | 66 20 4d 41 43 5f 43 0d |ndif..#i|f MAC_C.|
|00005b60| 09 2f 2a 0d 09 43 4c 55 | 54 53 49 5a 45 0d 09 49 |./*..CLU|TSIZE..I|
|00005b70| 6e 6c 69 6e 65 20 63 6f | 64 65 20 74 68 61 74 20 |nline co|de that |
|00005b80| 72 65 74 75 72 6e 73 20 | 74 68 65 20 73 61 6d 65 |returns |the same|
|00005b90| 20 61 6e 73 77 65 72 20 | 61 73 20 47 44 43 6c 75 | answer |as GDClu|
|00005ba0| 74 53 69 7a 65 28 64 65 | 76 69 63 65 29 2e 0d 09 |tSize(de|vice)...|
|00005bb0| 2a 2f 0d 09 23 64 65 66 | 69 6e 65 20 47 44 43 4c |*/..#def|ine GDCL|
|00005bc0| 55 54 53 49 5a 45 28 64 | 65 76 69 63 65 29 20 28 |UTSIZE(d|evice) (|
|00005bd0| 67 64 43 6c 75 74 53 69 | 7a 65 54 61 62 6c 65 5b |gdClutSi|zeTable[|
|00005be0| 28 2a 2a 28 2a 2a 28 64 | 65 76 69 63 65 29 29 2e |(**(**(d|evice)).|
|00005bf0| 67 64 50 4d 61 70 29 2e | 70 69 78 65 6c 53 69 7a |gdPMap).|pixelSiz|
|00005c00| 65 5d 29 0d 09 0d 09 2f | 2a 20 20 43 6f 6d 6d 65 |e])..../|* Comme|
|00005c10| 6e 74 65 64 20 6f 75 74 | 2c 20 62 65 63 61 75 73 |nted out|, becaus|
|00005c20| 65 20 69 74 73 20 61 6e | 73 77 65 72 20 69 73 20 |e its an|swer is |
|00005c30| 6d 69 73 6c 65 61 64 69 | 6e 67 20 77 68 65 6e 20 |misleadi|ng when |
|00005c40| 69 6e 20 31 36 2d 62 69 | 74 20 6f 72 20 33 32 2d |in 16-bi|t or 32-|
|00005c50| 62 69 74 20 6d 6f 64 65 | 2e 20 2a 2f 0d 09 2f 2a |bit mode|. */../*|
|00005c60| 20 23 64 65 66 69 6e 65 | 20 47 44 43 4f 4c 4f 52 | #define| GDCOLOR|
|00005c70| 53 28 64 65 76 69 63 65 | 29 20 28 28 2a 2a 28 2a |S(device|) ((**(*|
|00005c80| 2a 28 2a 2a 64 65 76 69 | 63 65 29 2e 67 64 50 4d |*(**devi|ce).gdPM|
|00005c90| 61 70 29 2e 70 6d 54 61 | 62 6c 65 29 2e 63 74 53 |ap).pmTa|ble).ctS|
|00005ca0| 69 7a 65 2b 31 29 20 2a | 2f 0d 23 65 6e 64 69 66 |ize+1) *|/.#endif|
|00005cb0| 0d 0d 2f 2a 0d 46 49 58 | 45 44 20 50 4f 49 4e 54 |../*.FIX|ED POINT|
|00005cc0| 20 41 52 49 54 48 4d 45 | 54 49 43 0d 41 70 70 6c | ARITHME|TIC.Appl|
|00005cd0| 65 20 64 65 66 69 6e 65 | 73 20 61 20 68 61 6e 64 |e define|s a hand|
|00005ce0| 79 20 64 61 74 61 20 74 | 79 70 65 20 63 61 6c 6c |y data t|ype call|
|00005cf0| 65 64 20 46 69 78 65 64 | 20 74 68 61 74 20 69 73 |ed Fixed| that is|
|00005d00| 20 73 74 6f 72 65 64 20 | 69 6e 20 61 20 6c 6f 6e | stored |in a lon|
|00005d10| 67 2c 20 62 75 74 20 69 | 73 0d 61 73 73 75 6d 65 |g, but i|s.assume|
|00005d20| 64 20 74 6f 20 68 61 76 | 65 20 61 20 64 65 63 69 |d to hav|e a deci|
|00005d30| 6d 61 6c 20 70 6f 69 6e | 74 20 69 6e 20 74 68 65 |mal poin|t in the|
|00005d40| 20 6d 69 64 64 6c 65 2e | 20 4d 61 6e 79 20 6f 70 | middle.| Many op|
|00005d50| 65 72 61 74 69 6f 6e 73 | 2c 20 65 2e 67 2e 20 61 |erations|, e.g. a|
|00005d60| 64 64 69 6e 67 20 74 77 | 6f 0d 46 69 78 65 64 20 |dding tw|o.Fixed |
|00005d70| 6e 75 6d 62 65 72 73 20 | 6f 72 20 6d 75 6c 74 69 |numbers |or multi|
|00005d80| 70 6c 79 69 6e 67 20 6f | 72 20 64 69 76 69 64 69 |plying o|r dividi|
|00005d90| 6e 67 20 61 20 46 69 78 | 65 64 20 62 79 20 61 6e |ng a Fix|ed by an|
|00005da0| 20 69 6e 74 65 67 65 72 | 2c 20 63 61 6e 20 62 65 | integer|, can be|
|00005db0| 20 70 65 72 66 6f 72 6d | 65 64 0d 64 69 72 65 63 | perform|ed.direc|
|00005dc0| 74 6c 79 2e 20 54 6f 20 | 6d 75 6c 74 69 70 6c 79 |tly. To |multiply|
|00005dd0| 20 6f 72 20 64 69 76 69 | 64 65 20 74 77 6f 20 46 | or divi|de two F|
|00005de0| 69 78 65 64 20 6e 75 6d | 62 65 72 73 20 75 73 65 |ixed num|bers use|
|00005df0| 20 41 70 70 6c 65 27 73 | 20 46 69 78 4d 75 6c 28 | Apple's| FixMul(|
|00005e00| 29 20 61 6e 64 0d 46 69 | 78 44 69 76 28 29 2e 20 |) and.Fi|xDiv(). |
|00005e10| 46 69 78 52 61 74 69 6f | 28 6e 2c 6d 29 20 72 65 |FixRatio|(n,m) re|
|00005e20| 74 75 72 6e 73 20 74 68 | 65 20 46 69 78 65 64 20 |turns th|e Fixed |
|00005e30| 72 61 74 69 6f 20 6f 66 | 20 74 77 6f 20 69 6e 74 |ratio of| two int|
|00005e40| 65 67 65 72 73 2e 20 4d | 61 63 69 6e 74 6f 73 68 |egers. M|acintosh|
|00005e50| 20 43 0d 63 6f 6d 70 69 | 6c 65 72 73 20 64 65 66 | C.compi|lers def|
|00005e60| 69 6e 65 20 64 6f 75 62 | 6c 65 20 69 6e 20 76 61 |ine doub|le in va|
|00005e70| 72 69 6f 75 73 20 77 61 | 79 73 2c 20 64 65 70 65 |rious wa|ys, depe|
|00005e80| 6e 64 69 6e 67 20 6f 6e | 20 77 68 65 74 68 65 72 |nding on| whether|
|00005e90| 20 61 20 66 6c 6f 61 74 | 69 6e 67 20 70 6f 69 6e | a float|ing poin|
|00005ea0| 74 0d 75 6e 69 74 20 69 | 73 20 74 6f 20 62 65 20 |t.unit i|s to be |
|00005eb0| 75 73 65 64 2e 20 54 68 | 65 20 41 70 70 6c 65 2d |used. Th|e Apple-|
|00005ec0| 70 72 6f 76 69 64 65 64 | 20 72 6f 75 74 69 6e 65 |provided| routine|
|00005ed0| 73 20 66 6f 72 20 64 6f | 69 6e 67 20 74 79 70 65 |s for do|ing type|
|00005ee0| 20 63 6f 6e 76 65 72 73 | 69 6f 6e 20 74 6f 20 61 | convers|ion to a|
|00005ef0| 6e 64 0d 66 72 6f 6d 20 | 46 69 78 65 64 20 61 72 |nd.from |Fixed ar|
|00005f00| 65 20 6f 6e 6c 79 20 61 | 70 70 72 6f 70 72 69 61 |e only a|ppropria|
|00005f10| 74 65 20 69 66 20 79 6f | 75 20 61 72 65 20 4e 4f |te if yo|u are NO|
|00005f20| 54 20 75 73 69 6e 67 20 | 74 68 65 20 66 6c 6f 61 |T using |the floa|
|00005f30| 74 69 6e 67 20 70 6f 69 | 6e 74 20 75 6e 69 74 2e |ting poi|nt unit.|
|00005f40| 0d 54 68 65 20 6f 6e 65 | 73 20 64 65 66 69 6e 65 |.The one|s define|
|00005f50| 64 20 62 65 6c 6f 77 20 | 61 72 65 20 66 61 73 74 |d below |are fast|
|00005f60| 65 72 20 61 6e 64 20 77 | 6f 72 6b 20 77 69 74 68 |er and w|ork with|
|00005f70| 20 6f 72 20 77 69 74 68 | 6f 75 74 20 74 68 65 20 | or with|out the |
|00005f80| 46 50 55 2e 0d 2a 2f 0d | 23 64 65 66 69 6e 65 20 |FPU..*/.|#define |
|00005f90| 4c 6f 6e 67 54 6f 46 69 | 78 28 78 29 20 28 28 6c |LongToFi|x(x) ((l|
|00005fa0| 6f 6e 67 29 28 78 29 3c | 3c 31 36 29 0d 23 64 65 |ong)(x)<|<16).#de|
|00005fb0| 66 69 6e 65 20 46 69 78 | 54 6f 4c 6f 6e 67 28 78 |fine Fix|ToLong(x|
|00005fc0| 29 20 28 28 78 29 3e 3e | 31 36 29 0d 23 64 65 66 |) ((x)>>|16).#def|
|00005fd0| 69 6e 65 20 44 6f 75 62 | 6c 65 54 6f 46 69 78 28 |ine Doub|leToFix(|
|00005fe0| 78 29 20 28 28 6c 6f 6e | 67 29 28 28 78 29 2a 36 |x) ((lon|g)((x)*6|
|00005ff0| 35 35 33 36 2e 2b 30 2e | 35 29 29 0d 23 64 65 66 |5536.+0.|5)).#def|
|00006000| 69 6e 65 20 46 69 78 54 | 6f 44 6f 75 62 6c 65 28 |ine FixT|oDouble(|
|00006010| 78 29 20 28 28 64 6f 75 | 62 6c 65 29 28 78 29 2a |x) ((dou|ble)(x)*|
|00006020| 28 31 2e 2f 36 35 35 33 | 36 2e 29 29 0d 0d 23 69 |(1./6553|6.))..#i|
|00006030| 66 20 4d 41 43 5f 43 0d | 09 2f 2a 0d 09 53 74 61 |f MAC_C.|./*..Sta|
|00006040| 63 6b 47 72 6f 77 28 6e | 29 20 69 6e 63 72 65 61 |ckGrow(n|) increa|
|00006050| 73 65 73 20 74 68 65 20 | 73 74 61 63 6b 20 61 6c |ses the |stack al|
|00006060| 6c 6f 63 61 74 69 6f 6e | 20 62 79 20 6e 20 62 79 |location| by n by|
|00006070| 74 65 73 2e 20 59 6f 75 | 27 6c 6c 20 61 6c 73 6f |tes. You|'ll also|
|00006080| 20 77 61 6e 74 20 74 6f | 20 75 73 65 0d 09 41 70 | want to| use..Ap|
|00006090| 70 6c 65 27 73 20 53 74 | 61 63 6b 53 70 61 63 65 |ple's St|ackSpace|
|000060a0| 28 29 2c 20 64 65 63 6c | 61 72 65 64 20 69 6e 20 |(), decl|ared in |
|000060b0| 4d 65 6d 6f 72 79 2e 68 | 2c 20 74 68 61 74 20 72 |Memory.h|, that r|
|000060c0| 65 74 75 72 6e 73 20 74 | 68 65 20 6e 75 6d 62 65 |eturns t|he numbe|
|000060d0| 72 20 6f 66 20 62 79 74 | 65 73 20 0d 09 61 6c 6c |r of byt|es ..all|
|000060e0| 6f 63 61 74 65 64 20 66 | 6f 72 20 74 68 65 20 73 |ocated f|or the s|
|000060f0| 74 61 63 6b 2e 0d 09 2a | 2f 0d 09 23 64 65 66 69 |tack...*|/..#defi|
|00006100| 6e 65 20 53 74 61 63 6b | 47 72 6f 77 28 65 78 74 |ne Stack|Grow(ext|
|00006110| 72 61 42 79 74 65 73 29 | 20 53 65 74 41 70 70 6c |raBytes)| SetAppl|
|00006120| 4c 69 6d 69 74 28 47 65 | 74 41 70 70 6c 4c 69 6d |Limit(Ge|tApplLim|
|00006130| 69 74 28 29 2d 28 65 78 | 74 72 61 42 79 74 65 73 |it()-(ex|traBytes|
|00006140| 29 29 0d 23 65 6e 64 69 | 66 0d 0d 23 69 66 20 4d |)).#endi|f..#if M|
|00006150| 41 43 5f 43 0d 09 2f 2a | 20 41 66 74 65 72 44 61 |AC_C../*| AfterDa|
|00006160| 72 6b 2e 63 20 2a 2f 0d | 0d 09 4f 53 45 72 72 20 |rk.c */.|..OSErr |
|00006170| 41 66 74 65 72 44 61 72 | 6b 45 6e 61 62 6c 65 28 |AfterDar|kEnable(|
|00006180| 76 6f 69 64 29 3b 0d 09 | 4f 53 45 72 72 20 41 66 |void);..|OSErr Af|
|00006190| 74 65 72 44 61 72 6b 44 | 69 73 61 62 6c 65 28 76 |terDarkD|isable(v|
|000061a0| 6f 69 64 29 3b 0d 23 65 | 6e 64 69 66 0d 0d 2f 2a |oid);.#e|ndif../*|
|000061b0| 20 41 73 73 69 67 6e 2e | 63 20 2a 2f 0d 0d 23 64 | Assign.|c */..#d|
|000061c0| 65 66 69 6e 65 20 41 53 | 53 49 47 4e 5f 44 49 4d |efine AS|SIGN_DIM|
|000061d0| 53 20 33 09 09 2f 2a 20 | 46 65 65 6c 20 66 72 65 |S 3../* |Feel fre|
|000061e0| 65 20 74 6f 20 69 6e 63 | 72 65 61 73 65 20 6f 72 |e to inc|rease or|
|000061f0| 20 64 65 63 72 65 61 73 | 65 20 41 53 53 49 47 4e | decreas|e ASSIGN|
|00006200| 5f 44 49 4d 53 2e 20 2a | 2f 0d 74 79 70 65 64 65 |_DIMS. *|/.typede|
|00006210| 66 20 73 74 72 75 63 74 | 20 7b 0d 09 73 68 6f 72 |f struct| {..shor|
|00006220| 74 20 74 79 70 65 3b 0d | 09 75 6e 73 69 67 6e 65 |t type;.|.unsigne|
|00006230| 64 20 73 69 7a 65 64 4f | 6e 63 65 3a 31 3b 09 2f |d sizedO|nce:1;./|
|00006240| 2a 20 64 69 6d 5b 5d 20 | 69 73 20 6d 65 61 6e 69 |* dim[] |is meani|
|00006250| 6e 67 66 75 6c 20 2a 2f | 0d 09 75 6e 73 69 67 6e |ngful */|..unsign|
|00006260| 65 64 20 73 69 7a 65 64 | 3a 31 3b 09 09 2f 2a 20 |ed sized|:1;../* |
|00006270| 64 69 6d 5b 5d 20 69 73 | 20 66 69 6e 61 6c 20 2a |dim[] is| final *|
|00006280| 2f 0d 09 75 6e 73 69 67 | 6e 65 64 20 6d 61 6c 6c |/..unsig|ned mall|
|00006290| 6f 63 65 64 3a 31 3b 09 | 2f 2a 20 61 6c 6c 6f 63 |oced:1;.|/* alloc|
|000062a0| 61 74 65 64 20 62 79 20 | 6d 61 6c 6c 6f 63 20 2a |ated by |malloc *|
|000062b0| 2f 0d 09 63 68 61 72 20 | 2a 6e 61 6d 65 3b 0d 09 |/..char |*name;..|
|000062c0| 76 6f 69 64 20 2a 70 74 | 72 3b 09 09 09 09 2f 2a |void *pt|r;..../*|
|000062d0| 20 66 6f 72 20 61 72 72 | 61 79 2c 20 61 64 64 72 | for arr|ay, addr|
|000062e0| 65 73 73 20 6f 66 20 65 | 6c 65 6d 65 6e 74 20 7a |ess of e|lement z|
|000062f0| 65 72 6f 20 2a 2f 0d 09 | 6c 6f 6e 67 20 64 69 6d |ero */..|long dim|
|00006300| 5b 41 53 53 49 47 4e 5f | 44 49 4d 53 5d 3b 09 2f |[ASSIGN_|DIMS];./|
|00006310| 2a 20 7a 65 72 6f 20 69 | 6e 64 69 63 61 74 65 73 |* zero i|ndicates|
|00006320| 20 61 20 73 63 61 6c 61 | 72 20 2a 2f 0d 09 6c 6f | a scala|r */..lo|
|00006330| 6e 67 20 66 69 72 73 74 | 45 6c 65 6d 65 6e 74 3b |ng first|Element;|
|00006340| 09 09 2f 2a 20 66 6f 72 | 20 31 2d 64 20 61 72 72 |../* for| 1-d arr|
|00006350| 61 79 2c 20 69 6e 64 65 | 78 20 6f 66 20 66 69 72 |ay, inde|x of fir|
|00006360| 73 74 20 61 72 72 61 79 | 20 65 6c 65 6d 65 6e 74 |st array| element|
|00006370| 2e 20 55 73 75 61 6c 6c | 79 20 30 20 2a 2f 0d 09 |. Usuall|y 0 */..|
|00006380| 63 6f 6e 73 74 20 63 68 | 61 72 20 2a 63 6f 6d 6d |const ch|ar *comm|
|00006390| 65 6e 74 3b 09 2f 2a 20 | 74 65 78 74 20 73 74 72 |ent;./* |text str|
|000063a0| 69 6e 67 2c 20 6f 72 20 | 4e 55 4c 4c 20 2a 2f 0d |ing, or |NULL */.|
|000063b0| 7d 20 44 65 73 63 72 69 | 70 74 69 6f 6e 3b 0d 65 |} Descri|ption;.e|
|000063c0| 6e 75 6d 7b 61 73 73 69 | 67 6e 52 65 70 6f 72 74 |num{assi|gnReport|
|000063d0| 55 6e 6b 6e 6f 77 6e 3d | 31 2c 61 73 73 69 67 6e |Unknown=|1,assign|
|000063e0| 4e 6f 48 65 78 49 6e 74 | 73 3d 32 2c 61 73 73 69 |NoHexInt|s=2,assi|
|000063f0| 67 6e 48 65 78 46 6c 6f | 61 74 73 3d 34 0d 09 2c |gnHexFlo|ats=4..,|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.